Flutter reload when variable changed?

I have a variable (string) called darklightmode. In my settings, this is always set to dark and light, depending on what button is pressed. Now I want this to change the theme in the build widget accordingly. I've already done all of that; the variable is also transferred to the main.dart file. However, the build widget doesn't update when the variable changes. Does anyone have any idea how I can solve this problem?

(1 votes)
Loading...

Similar Posts

Subscribe
Notify of
1 Answer
Oldest
Newest Most Voted
Inline Feedbacks
View all comments