GetX is a state management, dependency injection, and route management solution for Flutter.
Questions tagged [flutter-getx]
1530 questions
0
votes
2 answers
The argument type 'Object?' can't be assigned to the parameter type 'Map
I want to get a category section from Firebase Firestore so I used this class
class CategoryModel {
late String name, image;
CategoryModel({
required this.name,
required this.image,
});
CategoryModel.fromJson(Map…

sadji
- 92
- 5
0
votes
2 answers
The card color won't change when value of index is true on list that is observable
When I call the toggleSingleCardSelection, the isSelected of the chosen index will update but in my view, it will not fetch its updated data. Please help if I'm doing it the wrong way. I am also using the Get package. Using a stateful widget may…

RAlined
- 13
- 4
0
votes
1 answer
How do you get each timer count value? dart flutter
void main() {
final newTi = Get.put(NewTimer());
...
...
...: Obx((){
return Text('${newTi.count}');
// I'm trying to set a new timer and watch each of them.
// It's just 10. What should I do?
…

user16648824
- 21
- 2
0
votes
1 answer
Generic field/method in non-generic class in Dart
Is it possible, in Dart, to have generic methods in non-generic class, like in Java?
I use Getx for state management, DI & routing, but this question is not specific to Getx or Flutter.
I've AuthService which deals with authentication and sets…

manikanta
- 8,100
- 5
- 59
- 66
0
votes
2 answers
Flutter GetX why are controllers not auto-deleted when navigating away
Maybe I am misunderstanding something here, but I have followed the docs on https://pub.dev/packages/get to set up a controller for each of my pages.
e.g standard page stuff:
Pages:
PageIntro -> PageLogin -> PageHome etc.
Controllers:
-…

Dave
- 5,283
- 7
- 44
- 66
0
votes
1 answer
How to work with GetX Observable Variables?
I have a simple timer app whose UI includes this code snippet:
body: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Container(
width: 120,
height:…

Al C
- 5,175
- 6
- 44
- 74
0
votes
0 answers
Flutter sqflite insert does not store full data fetched using http get
I'm new to Flutter
my app fetches json records from the http get method and stores the data to database.
very thing works fine json returns around 149 rows but app only inserts 101 row in the table there is no error or anything.
Firstly I thought…

Savan Nagda
- 1
- 2
0
votes
0 answers
Flutter error - 'Null check operator used on a null value ( The following _CastError was thrown XXXXView ) '
I'm NEW to Flutter
I got this error when I run my flutter APP. I could not figure out why this error occurred .
PS: this error occurred after a navigate to another page from the bottom navigation section
This is how the error looks…

Hamza ayach
- 1
- 1
0
votes
2 answers
Can't get onChanged properly work with GetX
I am learning GetX. I am trying to write simple app that display text field and allow to edit it. So user can click on default text and continue to editing it.
But I am confused with onChange actions and controllers. I am not sure that I am using…

Dmitry Bubnenkov
- 9,415
- 19
- 85
- 145
0
votes
0 answers
Problem in showing data in ui in ListView Builder
I am sending data from my controller to my ui part i can't understand what the problem is and how to solve it. I tried every answer given on stackoverflow and many other websites but nothing seems to work for me:( i am sure my login part has no…

bahrulmaany
- 3
- 4
0
votes
2 answers
getx RxMap flutter
Could you help me, use package getx, when I use RxMap with the add method it does not let me add to the RxMap, check the getx package, but the add method is not in the rxmap

jose gonzalez
- 3
- 1
- 3
0
votes
1 answer
Getx: trigger obx in man class by obs value from other classes
I am trying to use Getx. I have a Home class .Inside Home I have a tab view.
return Scaffold(
appBar: AppBar(
centerTitle: true,
bottom:TabBar(
controller: controller.controller,
tabs: controller.myTabs,
),
actions: [
…

Cyrus the Great
- 5,145
- 5
- 68
- 149
0
votes
0 answers
Navigate to previous screen with updated data from api using GetX state management flutter
When I navigate back from update screen after updating I am uable to fetch updated data.
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Text("General Detail",style: TextStyle(fontFamily: 'Roboto',fontSize: 16.0,fontWeight:…

Hira Kauchha
- 79
- 1
- 7
0
votes
1 answer
The method 'fromSnapshot' isn't defined for the type 'Rx'
I'm getting the error The method 'fromSnapshot' isn't defined for the type 'Rx' and I am not sure why. Here is the code for the model:
class AgentsModel {
AgentsModel.fromSnapshot(DocumentSnapshot snapshot)
: cellPhone =…

LostTexan
- 431
- 5
- 18
0
votes
1 answer
Flutter - cannot download audio files
It's been 3 days that I try to fix an issue with the download of audio files with my Flutter application. When I try to download audio files, the request keep the "pending" status and finish with no error.
I have research a lot and find something…

Tryliom
- 895
- 1
- 12
- 37