Import apps/android/src/locales/types.ts
This commit is contained in:
parent
b080c8b8f2
commit
87a7f6ab73
|
|
@ -0,0 +1,9 @@
|
|||
import type zhCN from './zh-CN'
|
||||
|
||||
type WidenMessages<T> = T extends (...args: infer TArgs) => string
|
||||
? (...args: TArgs) => string
|
||||
: T extends string
|
||||
? string
|
||||
: { readonly [TKey in keyof T]: WidenMessages<T[TKey]> }
|
||||
|
||||
export type Messages = WidenMessages<typeof zhCN>
|
||||
Loading…
Reference in New Issue