nuxt-i18n
Advanced tools
Comparing version 6.20.3 to 6.20.4
@@ -0,1 +1,9 @@ | ||
### [6.20.4](https://github.com/nuxt-community/i18n-module/compare/v6.20.3...v6.20.4) (2021-03-01) | ||
### Bug Fixes | ||
* avoid using commonjs for runtime (vite support) ([3fc14ba](https://github.com/nuxt-community/i18n-module/commit/3fc14ba255f0791d5a8f13edd23a301e56665dca)) | ||
* use mjs version of klona ([#1079](https://github.com/nuxt-community/i18n-module/issues/1079)) ([bb0445d](https://github.com/nuxt-community/i18n-module/commit/bb0445db55403cc6e13b60df87d05a242d2e5463)) | ||
### [6.20.3](https://github.com/nuxt-community/i18n-module/compare/v6.20.2...v6.20.3) (2021-02-24) | ||
@@ -2,0 +10,0 @@ |
{ | ||
"name": "nuxt-i18n", | ||
"version": "6.20.3", | ||
"version": "6.20.4", | ||
"description": "i18n for Nuxt", | ||
@@ -92,12 +92,12 @@ "license": "MIT", | ||
"klona": "^2.0.4", | ||
"vue-i18n": "^8.18.1" | ||
"vue-i18n": "^8.23.0" | ||
}, | ||
"devDependencies": { | ||
"@babel/core": "7.12.17", | ||
"@babel/preset-env": "7.12.17", | ||
"@babel/runtime": "7.12.18", | ||
"@nuxt/types": "2.15.0", | ||
"@babel/core": "7.13.8", | ||
"@babel/preset-env": "7.13.8", | ||
"@babel/runtime": "7.13.8", | ||
"@nuxt/types": "2.15.2", | ||
"@nuxtjs/eslint-config-typescript": "5.0.0", | ||
"@nuxtjs/module-test-utils": "1.6.3", | ||
"@release-it/conventional-changelog": "2.0.0", | ||
"@release-it/conventional-changelog": "2.0.1", | ||
"@types/argparse": "2.0.5", | ||
@@ -114,4 +114,4 @@ "@types/finalhandler": "1.1.0", | ||
"codecov": "3.8.1", | ||
"core-js": "3.9.0", | ||
"eslint": "7.20.0", | ||
"core-js": "3.9.1", | ||
"eslint": "7.21.0", | ||
"finalhandler": "1.1.2", | ||
@@ -122,8 +122,8 @@ "jest": "26.6.3", | ||
"messageformat": "2.3.0", | ||
"nuxt": "2.15.0", | ||
"playwright-chromium": "1.8.1", | ||
"nuxt": "2.15.2", | ||
"playwright-chromium": "1.9.1", | ||
"release-it": "14.4.1", | ||
"serve-static": "1.14.1", | ||
"typescript": "4.1.5" | ||
"typescript": "4.2.2" | ||
} | ||
} |
@@ -73,3 +73,3 @@ import { resolve, join } from 'path' | ||
this.options.alias['~i18n-klona'] = require.resolve('klona/full') | ||
this.options.alias['~i18n-klona'] = require.resolve('klona/full').replace('.js', '.mjs') | ||
this.options.router.middleware.push('nuxti18n') | ||
@@ -76,0 +76,0 @@ this.options.render.bundleRenderer.directives = this.options.render.bundleRenderer.directives || {} |
@@ -14,3 +14,3 @@ <% | ||
if (key === 'vueI18n' && typeof value === 'string') { | ||
%>export const <%= key %> = require('<%= value %>').default | ||
%>export const <%= key %> = (context) => import('<%= value %>').then(m => m.default(context)) | ||
<% | ||
@@ -17,0 +17,0 @@ } else { |
@@ -39,2 +39,3 @@ import Vue from 'vue' | ||
} from './utils-common' | ||
import { loadLanguageAsync } from './utils' | ||
import { klona } from '~i18n-klona' | ||
@@ -94,3 +95,2 @@ | ||
if (lazy) { | ||
const { loadLanguageAsync } = require('./utils') | ||
const i18nFallbackLocale = app.i18n.fallbackLocale | ||
@@ -299,3 +299,3 @@ | ||
// Set instance options | ||
const vueI18nOptions = typeof vueI18n === 'function' ? vueI18n(context) : klona(vueI18n) | ||
const vueI18nOptions = typeof vueI18n === 'function' ? await vueI18n(context) : klona(vueI18n) | ||
vueI18nOptions.componentInstanceCreatedListener = extendVueI18nInstance | ||
@@ -302,0 +302,0 @@ app.i18n = new VueI18n(vueI18nOptions) |
import Cookie from 'cookie' | ||
import JsCookie from 'js-cookie' | ||
import isHTTPS from 'is-https' | ||
@@ -107,3 +108,2 @@ /** | ||
if (process.server) { | ||
const isHTTPS = require('is-https') | ||
protocol = (req && isHTTPS(req)) ? 'https' : 'http' | ||
@@ -110,0 +110,0 @@ } else { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
135639
Updatedvue-i18n@^8.23.0