hive_ui 1.0.14 copy "hive_ui: ^1.0.14" to clipboard
hive_ui: ^1.0.14 copied to clipboard

DBMS Hive Ui is a package that presents a smart methodology to work with the Hive database, It is easy to view, edit and create new rows.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:hive_ui/boxes_view.dart';

import 'boxes.dart';

void main() async {
  WidgetsFlutterBinding.ensureInitialized();
  runApp(const App());
  Boxes.initHive();
}

class App extends StatelessWidget {
  const App({super.key});

  @override
  Widget build(BuildContext context) {
    return const MaterialApp(
      title: "Hive UI",
      debugShowCheckedModeBanner: false,
      home: HomePage(),
    );
  }
}

class HomePage extends StatelessWidget {
  const HomePage({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Center(
        child: Column(
          crossAxisAlignment: CrossAxisAlignment.center,
          mainAxisAlignment: MainAxisAlignment.center,
          children: [
            MaterialButton(
              child: const Text("OPEN HIVE UI"),
              onPressed: () {
                Navigator.push(
                  context,
                  MaterialPageRoute(
                    builder: (context) => HiveBoxesView(
                      hiveBoxes: Boxes.allBoxes,
                      onError: (String errorMessage) => {
                        print(errorMessage),
                      },
                    ),
                  ),
                );
              },
            ),
            MaterialButton(
              child: const Text("Clear HIVE UI"),
              onPressed: () {
                Boxes.customersBox.clear();
              },
            ),

          ],
        ),
      ),
    );
  }
}
43
likes
120
pub points
84%
popularity

Publisher

verified publisherappsgateway.website

DBMS Hive Ui is a package that presents a smart methodology to work with the Hive database, It is easy to view, edit and create new rows.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

flutter, hive_flutter

More

Packages that depend on hive_ui