blob: a8a4d716cc4bdfd0b639b160d2cbcfded99b479a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
import Dexie, { type Table } from 'dexie';
export interface Chapter {
id: number;
chapters: number | null;
volumes: number | null;
}
export class ChapterDatabase extends Dexie {
chapters: Table<Chapter>;
constructor() {
super('chapterDatabase');
this.version(1).stores({
chapters: 'id, chapters, volumes'
});
this.chapters = this.table('chapters');
}
}
export const chapterDatabase = new ChapterDatabase();
|