1
0
Fork 1
mirror of https://github.com/elk-zone/elk.git synced 2024-11-19 23:40:07 +00:00

chore: fix build error

This commit is contained in:
Anthony Fu 2022-12-27 20:19:47 +01:00
parent 8f68fa12e4
commit 2d4f5ddf76

View file

@ -1,7 +1,6 @@
import { pwaInfo } from 'virtual:pwa-info' import { pwaInfo } from 'virtual:pwa-info'
import type { Link } from '@unhead/schema' import type { Link } from '@unhead/schema'
import type { Directions } from 'vue-i18n-routing' import type { Directions } from 'vue-i18n-routing'
import { init as initEmojis } from 'emoji-mart'
import { APP_NAME, STORAGE_KEY_LANG } from '~/constants' import { APP_NAME, STORAGE_KEY_LANG } from '~/constants'
import type { LocaleObject } from '#i18n' import type { LocaleObject } from '#i18n'
@ -76,8 +75,10 @@ export async function setupI18n() {
}) })
} }
export function setupEmojis() { export async function setupEmojis() {
initEmojis({ const promise = import('@emoji-mart/data').then(r => r.default)
data: () => import('@emoji-mart/data').then(r => r.default), const { init } = await import('emoji-mart')
init({
data: () => promise,
}) })
} }