import { createApp } from 'vue'
import { createI18n } from 'vue-i18n'
import App from './App.vue'
import router from './router'
import store from './store'
change `<router-link to="/">Home</router-link>` to `<router-link to="/">{{ $t('Home') }}</router-link>`
6. Run, and no error currently
`npm run serve`
7. Change the i18n content, save and recompile, a error will come out
{
"en": {
"Home": "|New Home"
}
}
### System Info
```shell
Win10
Node 16.13.1
npm 8.1.2
Chrome 110.0.5481.104
vue 3.2.47
vue-i18n 9.2.2
@intlify/vue-i18n-loader 4.2.0
@vue/cli 5.0.8
Reporting a bug?
I'm using the latest v9 vue-i18n, in my vue file
A compile error will occur
Syntax Error: Final loader (./node_modules/@intlify/vue-i18n-loader/lib/index.js) didn't return a Buffer or String
If I remove the
|
, no error come outBy the way, vue-i18n@8.28.2 dose not have this problem.
Expected behavior
Support | in i18n content.
Reproduction
Use vue-cli 5 to create a new project
vue create i18n9test
Install latest vue-i18n and @intlify/vue-i18n-loader
Config loader in vue.config.js
Use i18n in main.js
createApp(App).use(store).use(router).use(createI18n()).mount('#app')
Screenshot
No response
Additional context
No response
Validations