From 6da661bef3128d01570251d27648e184e28caec8 Mon Sep 17 00:00:00 2001 From: Linden <65407488+thelindat@users.noreply.github.com> Date: Sun, 14 Jan 2024 10:05:53 +1100 Subject: [PATCH] fix(package/locale): types --- package/shared/resource/locale/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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;