Category "dart"

Flutter unable to load image assets (Loading images through ListView.builder)

I tried to load from the assets/images folder using Listview.builder() but it keeps throwing this error: EXCEPTION CAUGHT BY IMAGE RESOURCE SERVICE The followi

Flutter web ignore resize

I would like to make my web app does not resize/responsive when the screen become smaller. For example when i decrease my browser size, instead of its adapting

How to set vertical and horizontal border in flutter datatable?

As I am new to flutter, I could not set the border in DataTable. Can anybody tell me how can I do that by using DataTable Widget? As per my requirement, I have

Flutter iOS version app crashed due to consuming high memory

I have developed a flutter app using the Bloc pattern. Everything was fine until we encountered a memory crash in iOS. The Android version works well without an

flutter- I don't know the difference between these two case

Case 1 : children: DUMMY_CATEGORIES.map((catData) { CategoryItem( catData.title, catData.color, ); }).toList(), Case 2 :

How to implement Uniformly Accelerated Motion Formula into Flutter Animation

I tried to create a Flutter Web App that can simulate Uniformly Accelerated Motion. So, I create a circle as the simulation object and some buttons. When the us

Refreshing a screen to update data in Flutter

I am trying to understand how to refresh my app screen with new data. The app is a dashboard that has several job cards and when another user applies something

How to generate List<TextSpan> dynamic?

Good Morning everyone, I Have different words of different lengths and I Need to create a dynamic List of TextSpan with every letter from the current word. I ha

Factory - A value of type 'B' can't be returned from the constructor 'A.factoryConstructor' because it has a return type of 'A<T>'

I have this simplified code: enum Types { b, c, } class A<T> { A(); factory A.factoryConstructor(Types type) { switch(type) { case Typ

The operator '[]' isn't defined for the type 'Object'. Flutter Dart

Hello, could you help me with this error, I don't know how to solve it import 'package:firebase_database/firebase_database.dart'; class Users { String id;

How to fix this issue ? FAILURE: Build failed with an exception

I try to add a package name as new_version: ^0.2.3. After the terminal return the below error. How can I fix this? FAILURE: Build failed with an exception. Wher

The method '[]' was called on null. Receiver: null Tried calling: []("main") console error

Hi i am working on a weather app i learnt from a course, everything was working fine till i start with the refactoring and it just got complicated the code show

Flutter : endDrawer icon hiden or actions button hiden

I had in my code a Drawer, and to hide the burger incon, i use "automaticallyImplyLeading = false". But now, i change to endDrawer and i dont know how the hide

I want to use custom font in Flutter Image.drawString

This is about Flutter, Dart, Image, specifically drawString function. First of all, what I am trying to do is watermark the picture taken with the address and t

How to write an expression into a method?

How can I write the expression into a separate method for optimization: final listOfKeys= [_firstTabNavKey, _secondTabNavKey, _thirdTabNavKey] onWillPop: (

How to solve flutter web api cors error only with dart code?

It seems like CORS error is well-known issue in the web field. But I tried flutter web for the first time ever and I faced critical error. The code below worked

Explict generic type in function by default replace this type to dynamic inside

Why explict generic type in function by default replace this type to dynamic inside? example: class Boo { void displayType<int>() { print('type int

How to assign the non-nullable local variable "_msg"

I'm trying to make a Login form in flutter using a string function here is the code: String validateEmail(String value) { String _msg; RegExp regex = RegExp

Bloc depends on unregistered type - Injectable

I'm using injectable lib according to a tutorial in youtube some of annotations replaced. but I visit injectable lib in pub.dev look to the changelog and replac

How to get OTP from SMS - autofill

I want to catch or read OTP of SMS messages automatically. I did some tests like this code : import 'package:flutter/material.dart'; void main() { runApp(MyA