From: Chris Duncan Date: Sun, 21 Sep 2025 21:33:12 +0000 (-0700) Subject: Update getter docs. X-Git-Tag: v0.10.5~12^2~28 X-Git-Url: https://git.codecow.com/?a=commitdiff_plain;h=73942e0b421302021854b9e205342d47f1ac659e;p=libnemo.git Update getter docs. --- diff --git a/src/lib/database.ts b/src/lib/database.ts index db6b9de..b6a7ef4 100644 --- a/src/lib/database.ts +++ b/src/lib/database.ts @@ -7,9 +7,15 @@ import { Data, NamedData } from '#types' * Encrypts and stores data in the browser using IndexedDB. */ export class Database { - static DB_NAME = 'libnemo' - static DB_STORES = ['Wallet', 'Account', 'Rolodex'] static #storage: IDBDatabase + /** + * @returns {'libnemo'} + */ + static get DB_NAME (): 'libnemo' { return 'libnemo' } + /** + * @returns {['Wallet', 'Account', 'Rolodex']} + */ + static get DB_STORES (): ['Wallet', 'Account', 'Rolodex'] { return ['Wallet', 'Account', 'Rolodex'] } /** * Inserts records in a datastore, throwing if they already exist. diff --git a/src/lib/rolodex.ts b/src/lib/rolodex.ts index ec2b9ed..f3de895 100644 --- a/src/lib/rolodex.ts +++ b/src/lib/rolodex.ts @@ -11,7 +11,11 @@ import { Tools } from './tools' * saved under one nickname. */ export class Rolodex { + /** + * @returns {'Rolodex'} + */ static get DB_NAME (): 'Rolodex' { return 'Rolodex' } + /** * Adds an address to the rolodex under a specific nickname. * diff --git a/src/lib/wallet/index.ts b/src/lib/wallet/index.ts index 8ad399e..e3bf410 100644 --- a/src/lib/wallet/index.ts +++ b/src/lib/wallet/index.ts @@ -33,6 +33,9 @@ export type WalletType = 'BIP-44' | 'BLAKE2b' | 'Ledger' * three types of wallets are supported: BIP-44, BLAKE2b, and Ledger. */ export class Wallet { + /** + * @returns {'Wallet'} + */ static get DB_NAME (): 'Wallet' { return 'Wallet' } /**