mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-14 09:20:51 +08:00
10 lines
227 B
TypeScript
10 lines
227 B
TypeScript
|
import { computed } from 'vue'
|
||
|
import { useLang } from './lang'
|
||
|
|
||
|
export const useLocale = (
|
||
|
localeJson: Record<string, Record<string, string>>
|
||
|
) => {
|
||
|
const lang = useLang()
|
||
|
return computed(() => localeJson[lang.value])
|
||
|
}
|