@jota-one/i36n
Advanced tools
Comparing version 2.0.0 to 2.1.0
@@ -12,2 +12,3 @@ declare function $label(key: string, params: object, lang: string, markdown: boolean): string; | ||
$label: Function | ||
loadTranslations: Function | ||
} | ||
@@ -14,0 +15,0 @@ |
{ | ||
"name": "@jota-one/i36n", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"description": "Translation manager twice simpler and twice better", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -61,2 +61,7 @@ import { ref, reactive, watch, computed, provide, inject } from 'vue' | ||
const loadTranslations = async ln => { | ||
labels[ln] = await load(ln) | ||
loaded.value += 1 | ||
} | ||
let _switching = false | ||
@@ -68,4 +73,3 @@ watch(() => currentLanguage.value, async ln => { | ||
if (!labels[ln]) { | ||
labels[ln] = await load(ln) | ||
loaded.value += 1 | ||
await loadTranslations(ln) | ||
} | ||
@@ -80,3 +84,4 @@ | ||
showKey, | ||
$label | ||
$label, | ||
loadTranslations, | ||
} | ||
@@ -83,0 +88,0 @@ |
@@ -61,2 +61,7 @@ import { ref, reactive, watch, computed, provide, inject } from '@vue/composition-api' | ||
const loadTranslations = async ln => { | ||
labels[ln] = await load(ln) | ||
loaded.value += 1 | ||
} | ||
let _switching = false | ||
@@ -68,4 +73,3 @@ watch(() => currentLanguage.value, async ln => { | ||
if (!labels[ln]) { | ||
labels[ln] = await load(ln) | ||
loaded.value += 1 | ||
await loadTranslations(ln) | ||
} | ||
@@ -80,3 +84,4 @@ | ||
showKey, | ||
$label | ||
$label, | ||
loadTranslations, | ||
} | ||
@@ -83,0 +88,0 @@ |
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
10669
179