lib item page ready

This commit is contained in:
Dr-Blank 2024-05-12 05:38:30 -04:00
parent 0d54f1cb15
commit 097caf8ec2
No known key found for this signature in database
GPG key ID: 7452CC63F210A266
15 changed files with 804 additions and 221 deletions

View file

@ -2,6 +2,7 @@
import 'dart:io';
import 'package:flutter/material.dart';
import 'package:hive/hive.dart';
import 'package:path/path.dart' as p;
import 'package:path_provider/path_provider.dart';
@ -15,12 +16,13 @@ Future initStorage() async {
// use whispering_pages as the directory for hive
final storageDir = Directory(p.join(
dir.path,
AppMetadata.appName.toLowerCase().replaceAll(' ', '_'),
AppMetadata.appNameLowerCase,
),
);
await storageDir.create(recursive: true);
Hive.defaultDirectory = storageDir.path;
debugPrint('Hive storage directory init: ${Hive.defaultDirectory}');
await registerModels();
}