@vizejs/nuxt 0.237.0 → 0.239.0
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/index.mjs +8 -2
- package/package.json +4 -4
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createRequire } from "node:module";
|
|
2
2
|
import { addServerPlugin, addVitePlugin, createResolver, defineNuxtModule, getNuxtVersion, isNuxt2 } from "@nuxt/kit";
|
|
3
3
|
import fs from "node:fs";
|
|
4
|
-
import path from "node:path";
|
|
4
|
+
import path, { dirname } from "node:path";
|
|
5
5
|
import { createHash } from "node:crypto";
|
|
6
6
|
//#region src/components.ts
|
|
7
7
|
const COMPONENT_CALL_RE = /_?resolveComponent\s*\(\s*["'`]([^"'`]+)["'`]\s*(?:,\s*[^)]+)?\)/g;
|
|
@@ -703,6 +703,12 @@ function resolveNuxtMuseaOptions(musea) {
|
|
|
703
703
|
if (musea === false || musea == null) return false;
|
|
704
704
|
return musea;
|
|
705
705
|
}
|
|
706
|
+
//#endregion
|
|
707
|
+
//#region src/resolver.ts
|
|
708
|
+
const nodeRequire = createRequire(`${process.cwd()}/package.json`);
|
|
709
|
+
function createNuxtModuleResolver() {
|
|
710
|
+
return createResolver(dirname(nodeRequire.resolve("@vizejs/nuxt")));
|
|
711
|
+
}
|
|
706
712
|
function readTextFile(filePath) {
|
|
707
713
|
return fs.readFileSync(filePath, "utf-8");
|
|
708
714
|
}
|
|
@@ -850,7 +856,7 @@ var src_default = defineNuxtModule({
|
|
|
850
856
|
nuxtMusea: { route: { path: "/" } }
|
|
851
857
|
},
|
|
852
858
|
async setup(options, nuxt) {
|
|
853
|
-
const resolver =
|
|
859
|
+
const resolver = createNuxtModuleResolver();
|
|
854
860
|
const detectedNuxtMajor = options.compatibility?.nuxtVersion ?? getDetectedNuxtMajor(nuxt) ?? 3;
|
|
855
861
|
const vueVersion = options.compatibility?.vueVersion ?? (detectedNuxtMajor === 2 ? 2 : 3);
|
|
856
862
|
const nuxtWithBuilderOptions = nuxt;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vizejs/nuxt",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.239.0",
|
|
4
4
|
"description": "Nuxt module for Vize - compiler, musea gallery, linter, and type checker",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"compiler",
|
|
@@ -42,9 +42,9 @@
|
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@nuxt/kit": "4.4.8",
|
|
45
|
-
"@vizejs/vite-plugin": "0.
|
|
46
|
-
"@vizejs/vite-plugin-musea": "0.
|
|
47
|
-
"vize": "0.
|
|
45
|
+
"@vizejs/vite-plugin": "0.239.0",
|
|
46
|
+
"@vizejs/vite-plugin-musea": "0.239.0",
|
|
47
|
+
"vize": "0.239.0"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"typescript": "6.0.3",
|