About Cubit :

_Cubit is a lightweight state management solution. It is a subset of the _bloc package_ that does not rely on events and instead uses methods to emit new states._

Every _cubit_ requires an initial state which will be the state of the _cubit_ before _emit_ has been called. The current state of a _cubit_ can be accessed via the _state_ getter.

The cubit package is a collection of different packages for cubit such as cubitflutter cubit,** hydrated cubit**,** replay cubit**,** cubit test**, and a** cubit angular **and all these have their own functionalities that they bring in the scenario.

In all these packages the main package cubit used if you have plain old dart project and want to use functionalities of cubit state management.

Flutter cubit

flutter cubit consists of all the functionalities of the main cubit package and also provides other different functionalities for different kinds of widgets and one important thing it also uses the functionalities of provider package.

Hydrated cubit

It persists and restores data in the hive database and you can get the data and read it out after you have restarted your application.

Replay cubit

It allows you to redo and undo certain states, for example, you if want to delete your data or want to retrieve it again.

Remaining two packages cubit test is used for testing the framework and cubit angular is used in the angular framework

#cubit #state-management #provider #bloc #flutter

Cubit State Management Flutter
131.90 GEEK