mirror of
https://github.com/hydralauncher/hydra.git
synced 2026-01-22 02:13:59 +00:00
fix: removing unused navigate
This commit is contained in:
3
src/main/level/index.ts
Normal file
3
src/main/level/index.ts
Normal file
@@ -0,0 +1,3 @@
|
||||
export { db } from "./level";
|
||||
|
||||
export * from "./sublevels";
|
||||
4
src/main/level/level.ts
Normal file
4
src/main/level/level.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import { levelDatabasePath } from "@main/constants";
|
||||
import { Level } from "level";
|
||||
|
||||
export const db = new Level(levelDatabasePath, { valueEncoding: "json" });
|
||||
7
src/main/level/sublevels/games.ts
Normal file
7
src/main/level/sublevels/games.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
import { Game } from "@types";
|
||||
import { db } from "../level";
|
||||
import { levelKeys } from "./keys";
|
||||
|
||||
export const gamesSublevel = db.sublevel<string, Game>(levelKeys.games, {
|
||||
valueEncoding: "json",
|
||||
});
|
||||
1
src/main/level/sublevels/index.ts
Normal file
1
src/main/level/sublevels/index.ts
Normal file
@@ -0,0 +1 @@
|
||||
export * from "./games";
|
||||
8
src/main/level/sublevels/keys.ts
Normal file
8
src/main/level/sublevels/keys.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import type { GameShop } from "@types";
|
||||
|
||||
export const levelKeys = {
|
||||
games: "games",
|
||||
game: (shop: GameShop, objectId: string) => `${shop}:${objectId}`,
|
||||
user: "user",
|
||||
auth: "auth",
|
||||
};
|
||||
Reference in New Issue
Block a user