fully integrated vue-i18n with embeded en messages and async loaded current language translation exported by strings_translation_export_json

This commit is contained in:
2020-12-08 15:26:56 +01:00
parent 07a48670ff
commit e6c452629c
22 changed files with 873 additions and 12539 deletions

View File

@@ -14,7 +14,9 @@ module.exports = {
'vue': 'vue/dist/vue.js',
'theme': utils.resolve(themePath),
'vuejs': utils.resolve(themePath+'/vuejs'),
'assets': utils.resolve(themePath+'/assets')
'assets': utils.resolve(themePath+'/assets'),
// locales are exported by strings_i18n_json_export from drupal
'locales': utils.resolve('web/sites/default/files/lang')
}
},
entry: {
@@ -40,11 +42,11 @@ module.exports = {
test: /\.vue$/,
use: 'vue-loader'
},
{
resourceQuery: /blockType=i18n/,
type: 'javascript/auto',
loader: '@kazupon/vue-i18n-loader'
},
// {
// resourceQuery: /blockType=i18n/,
// type: 'javascript/auto',
// loader: '@kazupon/vue-i18n-loader'
// },
{
test: /\.js$/,
use: {