@dargmuesli/nuxt-cookie-control 5.0.1 → 5.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/module.json +1 -1
- package/dist/module.mjs +3 -2
- package/package.json +1 -1
package/dist/module.json
CHANGED
package/dist/module.mjs
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { resolve } from 'node:path';
|
|
2
|
+
import { pathToFileURL } from 'node:url';
|
|
2
3
|
import { createResolver, defineNuxtModule, addPlugin, addImports, addTemplate, extendWebpackConfig, resolvePath } from '@nuxt/kit';
|
|
3
4
|
|
|
4
5
|
const name = "@dargmuesli/nuxt-cookie-control";
|
|
5
|
-
const version = "5.0.
|
|
6
|
+
const version = "5.0.2";
|
|
6
7
|
|
|
7
8
|
const en = {
|
|
8
9
|
accept: "Accept",
|
|
@@ -148,7 +149,7 @@ const loadLocales = async (moduleOptions) => {
|
|
|
148
149
|
const locales = moduleOptions.locales;
|
|
149
150
|
moduleOptions.locales = [];
|
|
150
151
|
for (const locale of locales) {
|
|
151
|
-
const text = await import(await resolvePath(resolve(runtimeDir, "locale", locale))).then((r) => r.default || r);
|
|
152
|
+
const text = await import(pathToFileURL(await resolvePath(resolve(runtimeDir, "locale", locale))).href).then((r) => r.default || r);
|
|
152
153
|
if (!text)
|
|
153
154
|
throw new Error(`Could not import text for locale ${locale}`);
|
|
154
155
|
moduleOptions.locales.push(locale);
|