We will cover briefly about

  1. Storing data using Hive

  2. Data operations

  3. Real-time UI updates

Storing data using Hive

Hive is a lightweight and key-value database. It supports mobile, desktop, and browser.

We can save data from primitives like strings to complex custom objects.

Note: Install both hive and hive_flutter

Configure Hive

Inside your main.dart, initialize Hive using

await Hive.initFlutter();

and register the adapter which was generated using code generation above. We specify the type of model (in our case ArticlesModel).