naming
This commit is contained in:
parent
dc97357e5e
commit
6fb1ab03ca
|
@ -21,7 +21,7 @@ export default function pluginWatchLocales() {
|
|||
if (localeYmlPaths.includes(filePath)) {
|
||||
server.ws.send({
|
||||
type: 'custom',
|
||||
event: 'language-update',
|
||||
event: 'locale-update',
|
||||
data: filePath.match(/([^\/]+)\.yml$/)?.[1] || null,
|
||||
})
|
||||
}
|
||||
|
|
|
@ -100,8 +100,8 @@ export async function common(createVue: () => Promise<App<Element>>) {
|
|||
}
|
||||
|
||||
if (import.meta.hot) {
|
||||
import.meta.hot.on('language-update', async (updatedLang: string) => {
|
||||
console.info(`Language updated: ${updatedLang}`);
|
||||
import.meta.hot.on('locale-update', async (updatedLang: string) => {
|
||||
console.info(`Locale updated: ${updatedLang}`);
|
||||
if (updatedLang === lang) {
|
||||
await new Promise(resolve => {
|
||||
window.setTimeout(resolve, 500);
|
||||
|
|
Loading…
Reference in New Issue