@canofold/vite 0.3.2 → 0.3.3

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.
Files changed (2) hide show
  1. package/dist/index.js +4 -0
  2. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -441,6 +441,10 @@ async function isolatedBuildConfig(context, options, plugin, build) {
441
441
  delete sharedConfig.preview;
442
442
  const engineConfig = {
443
443
  ...inlineConfig(context.cwd, context.basePath, { ...options, configFile: false }, plugin),
444
+ // The demo bundle is emitted below the site's own asset directory. Vite 8
445
+ // resolves preload dependencies from `base`, so using the site root here
446
+ // would incorrectly request demo chunks from `/chunks` and `/assets`.
447
+ base: baseUrl(context.basePath, "/assets/canofold-demos/"),
444
448
  mode: "production",
445
449
  define: {
446
450
  "process.env.NODE_ENV": JSON.stringify("production")
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@canofold/vite",
3
- "version": "0.3.2",
3
+ "version": "0.3.3",
4
4
  "description": "Official Vite demo engine for interactive Canofold component documentation.",
5
5
  "license": "MIT",
6
6
  "author": "Canofold Contributors",
@@ -42,10 +42,10 @@
42
42
  "provenance": true
43
43
  },
44
44
  "dependencies": {
45
- "@canofold/markdown": "0.3.2"
45
+ "@canofold/markdown": "0.3.3"
46
46
  },
47
47
  "peerDependencies": {
48
- "canofold": "^0.3.2",
48
+ "canofold": "^0.3.3",
49
49
  "react": "^18.2.0 || ^19.0.0",
50
50
  "react-dom": "^18.2.0 || ^19.0.0",
51
51
  "vite": "^6.4.0 || ^7.0.0 || ^8.0.0"
@@ -58,7 +58,7 @@
58
58
  "typescript": "^6.0.3",
59
59
  "vite": "^6.4.3",
60
60
  "vitest": "^4.1.11",
61
- "canofold": "0.3.2"
61
+ "canofold": "0.3.3"
62
62
  },
63
63
  "scripts": {
64
64
  "build": "tsup",