@vizejs/nuxt 0.794.0 → 0.796.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 CHANGED
@@ -1277,6 +1277,16 @@ function mergePlainRecords(...values) {
1277
1277
  //#endregion
1278
1278
  //#region src/vite-compiler.ts
1279
1279
  /**
1280
+ * Nuxt writes its generated root tsconfig to `typesDir` (Nuxt 4.7+), falling
1281
+ * back to `buildDir` before that option existed. A production build that runs
1282
+ * after `nuxt prepare` or `nuxt dev` builds into a cache `buildDir` and keeps
1283
+ * the tsconfigs in `typesDir`, so `buildDir` is not where they are.
1284
+ */
1285
+ function nuxtTypeResolutionFallback(host) {
1286
+ const typesDir = host.typesDir || host.buildDir;
1287
+ return typesDir ? { typeResolutionFallbackTsconfig: resolve(typesDir, "tsconfig.json") } : {};
1288
+ }
1289
+ /**
1280
1290
  * Keep lazy plugin loading and native-only registration outside the module
1281
1291
  * entry. Vize's SFC compile stage takes the host compiler's place in each
1282
1292
  * config; this hook runs before the module's own, which drops that compiler.
@@ -1291,7 +1301,7 @@ async function setupNuxtViteCompiler(compilerOptions, nuxt, compiler) {
1291
1301
  ...explicit,
1292
1302
  nuxtPageMeta: true,
1293
1303
  ssrModuleIdRoot: host.srcDir,
1294
- ...host.buildDir ? { typeResolutionFallbackTsconfig: resolve(host.buildDir, "tsconfig.json") } : {}
1304
+ ...nuxtTypeResolutionFallback(host)
1295
1305
  }, defaults, "nuxt");
1296
1306
  host.vite.plugins.push(plugins);
1297
1307
  const stage = plugins.find((plugin) => plugin.name === "vite-plugin-vize:sfc");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vizejs/nuxt",
3
- "version": "0.794.0",
3
+ "version": "0.796.0",
4
4
  "description": "Nuxt module for Vize - compiler, musea gallery, linter, and type checker",
5
5
  "keywords": [
6
6
  "compiler",
@@ -50,16 +50,16 @@
50
50
  },
51
51
  "dependencies": {
52
52
  "@nuxt/kit": "3.21.8",
53
- "@vizejs/native": "0.794.0",
54
- "@vizejs/nuxt-lint-config": "0.794.0",
55
- "@vizejs/vite-plugin": "0.794.0",
56
- "@vizejs/vite-plugin-musea": "0.794.0",
57
- "vize": "0.794.0"
53
+ "@vizejs/native": "0.796.0",
54
+ "@vizejs/nuxt-lint-config": "0.796.0",
55
+ "@vizejs/vite-plugin": "0.796.0",
56
+ "@vizejs/vite-plugin-musea": "0.796.0",
57
+ "vize": "0.796.0"
58
58
  },
59
59
  "devDependencies": {
60
60
  "jiti-nuxt2": "npm:jiti@1.21.7",
61
61
  "oxlint": "1.78.0",
62
- "oxlint-plugin-vize": "0.794.0",
62
+ "oxlint-plugin-vize": "0.796.0",
63
63
  "typescript": "6.0.3",
64
64
  "vite": "npm:@voidzero-dev/vite-plus-core@1.5.0",
65
65
  "vite-plus": "1.5.0",
@@ -1,4 +1,5 @@
1
- // Generated from tools/config/pkl/package-tasks/npm/framework/nuxt/tasks.pkl
1
+ // DO NOT EDIT. Generated from tools/config/pkl/package-tasks/npm/framework/nuxt/tasks.pkl.
2
+ // Edit the Pkl source and run `node tools/commands/generate/repository-config.ts`.
2
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
4
  //#region \0rolldown/runtime.js
4
5
  var __create = Object.create;