-
Hello, I'm new of state manager, I'm just started to learning. If you're using the GetX package, you can add it as a service that manages the database instance:.
here my actual code:
and inside the screens where I need to manage data:
or to to add an Order:
and in the main.dart:
Can you help me to convert it to use getX? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
It's impossible to see what kind of class |
Beta Was this translation helpful? Give feedback.
It's impossible to see what kind of class
Get
is from the dartdoc of that package, but if it's a global dependency manager then you could doGet.put(AppDb())
inmain
and then use the database withGet.find<AppDb>()
where you are currently using provider.