mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-15 18:01:24 +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])
|
||
|
}
|