Ben Lin
2024-10-28 08abfcfea8247c394b2034cad59734846b403dd9
src/locales/setupI18n.ts
@@ -1,5 +1,13 @@
/*
 * @Description: file content
 * @Author: Ben Lin
 * @version:
 * @Date: 2024-06-18 15:09:47
 * @LastEditors: Ben Lin
 * @LastEditTime: 2024-07-17 04:31:26
 */
import type { App } from 'vue';
import type { I18nOptions } from 'vue-i18n';
import type { I18n, I18nOptions } from 'vue-i18n';
import { createI18n } from 'vue-i18n';
import { setHtmlPageLang, setLoadLocalePool } from './helper';
@@ -39,6 +47,6 @@
// setup i18n instance with glob
export async function setupI18n(app: App) {
  const options = await createI18nOptions();
  i18n = createI18n(options);
  i18n = createI18n(options) as I18n;
  app.use(i18n);
}