diff --git a/package/shared/resource/locale/index.ts b/package/shared/resource/locale/index.ts index 4025431..8a264d5 100644 --- a/package/shared/resource/locale/index.ts +++ b/package/shared/resource/locale/index.ts @@ -1,9 +1,9 @@ import { cache } from '../cache/index'; import { printf } from 'fast-printf'; -const dict: { [key: string]: string | number } = {}; +const dict: Record = {}; -export const locale = (str: keyof typeof dict, ...args: any[]) => { +export const locale = (str: string, ...args: any[]) => { const lstr = dict[str]; if (!lstr) return str;