Category "dart"

Flutter : audio_service with Video player

how can i use audio_service package with video player(ex : chewie or pod_player ) to play video in background and Android lock screen and notification, iOS cont

Flutter / Dart Convert Int to Enum

Is there a simple way to convert an integer value to enum? I want to retrieve an integer value from shared preference and convert it to an enum type. My enum i

Adding box shadow to TextInputField flutter

I was working on a project involving inputs. I want a box-shadow to an input. I have tried the BoxShadow widget on the container but it drops the shadow on the

Parsing Nested JSON within Flutter

I am trying to parse nested JSON from the VirusTotal API but when ran it comes back as this error, I tried a different method found in https://app.quicktype.io/

Upgraded to Flutter 3.0 from 2.8.1, getting: Warning: Operand of null-aware operation '?.' has type 'PaintingBinding' which excludes null error

Upgraded to Flutter 3.0 from 2.8.1, getting: Warning: Operand of null-aware operation '?.' has type 'PaintingBinding' which excludes null error It's on binding.

How to add a File Picker plugin in Flutter?

I am creating a Flutter project in which, I have a piece of data (JSON) that I want to Import from and Export to a location the user wants to. In order to achie

How to programmatically select BottomNavigationBar Tab in Flutter instead of built in onTap callback?

I have been working with BottomNavigationBar in the flutter, but I am not able to select a Tab programmatically outside of onTap callback of BottomNavigationBar

How to add image in Flutter

I am developing Flutter app for the first time.. I have an issue in adding a image. I have a below questions : Where to create images folder? Where to add asse

Flutter: Incorrect use of ParentDataWidget

I'm trying to do a homepage where it will scrollable with 3 or 4 titles and a horizontal lists for products once i put the ListView.builder i get this error: In

How to send email from a Flutter Web application?

I'm trying to send email from a Flutter Web application using mailer package but I'm getting this error: Unsupported operation: Socket constructor It seem

Sort maps in Dart by key or by value

I have the following map Map testMap = { 3 : { 'order': 3, 'sample' : 'sample' }, 2 : { 'order': 2, 'sample' : 'sample' }, 1 : {

OAuth2: No login dialog after log out, direct log in of last user

I am building a flutter app that needs the user to authenticate against an identity provider in order to user the app. I am using the package simple_auth_flutt

How to show waves while record an audio using flutter sound

i am using flutter_sound_lite package to record users voices and i am trying to show the waves while user is recording but couldn't do that i need something sim

how to implement in app time out session in flutter

I want to log a user out after a specific amount time the user has not interacted with the app. I've wrapped the whole child widget in GestureDetector(). Ple

Flutter Riverpod ref.read() vs ref.listen() vs ref.watch()

After reading the documentation, it did not explain very well what ref.read(), ref.watch(), and ref.listen() is. The questions I have are as follows: What is th

How to test navigation via Navigator in Flutter

Let's say, I have a test for a screen in Flutter using WidgetTester. There is a button, which executes a navigation via Navigator. I would like to test behavior

Flutter: How can I highlights parameter-hint in visual studio code

I am using flutter in Visual Studio Code. I want to highlight parameter hints. If you see the picture, you can see that it's not colored. It's quite hard to

Rename a file/Image in flutter

I am picking a image from gallery/taking a photo using image_picker: ^0.6.2+3 package. File picture = await ImagePicker.pickImage( maxWidth: 800, imageQual

Flutter 2: Button with icon and text

Since RaisedButton, FlatButton, etc. have been deprecated, are there any button widgets that provide text and icons to prevent row creation or other workarounds

How to remove hash (#) from URL in Flutter web

The default URL of a Flutter web project defines a URL containing a hashtag (#), as follows: http://localhost:41521/#/peaple/... I would like to remove this '#