chore: init project

This commit is contained in:
vben
2024-05-19 21:20:42 +08:00
commit 399334ac57
630 changed files with 45623 additions and 0 deletions

View File

@@ -0,0 +1,17 @@
import type { App } from 'vue';
import { i18n, loadLocaleMessages } from './i18n';
import type { LocaleSetupOptions } from './typing';
const $t = i18n.global.t;
async function setupI18n(app: App, options: LocaleSetupOptions = {}) {
const { defaultLocale = 'zh-CN' } = options;
app.use(i18n);
await loadLocaleMessages(defaultLocale);
}
export { $t, loadLocaleMessages, setupI18n };
export type { CompileError } from '@intlify/core-base';
export { useI18n } from 'vue-i18n';