Posts

Showing posts from June, 2020

State Management in Flutter

Image
Flutter is one of the new tools in the business. But all the features that it packs along with dart as the main language, it had made me fall in love with it. One thing that makes, Flutter versatile is State Management. The concept of State management is quite complicated but also easily simple what you need to do is start with basics. So, let's get started.  The state corresponds to the local data that a widget can hold which is available after the widget has rendered.   Whenever we set the state the build function of the widget is triggered, refreshing the user interface of the widget. For example, if we change the value of a variable in runtime in a flutter application. If that part of the application which uses that variable is stateless the change of variable in runtime will not show in the screen, i.e., the state of variable change will now make flutter repaint that widget on the screen. But in the case of  Stateful Widget, In case of any change to variable in an application