@bndynet/vue-site 0.1.6 → 0.1.8

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/bin/vue-site.mjs +9 -0
  2. package/package.json +1 -1
package/bin/vue-site.mjs CHANGED
@@ -388,6 +388,15 @@ async function buildViteConfig(options = {}) {
388
388
  'vue-router': resolve(vueRouterPath, 'dist/vue-router.mjs'),
389
389
  },
390
390
  },
391
+ optimizeDeps: {
392
+ // Pre-bundle element-plus so Vite crawls its dependency graph and
393
+ // discovers dayjs (a CJS/UMD package with no ESM default export).
394
+ // Without this, dayjs.min.js is served raw to the browser and
395
+ // Element Plus throws "does not provide an export named 'default'".
396
+ // The virtual entry only imports element-plus CSS, so Vite's static
397
+ // analysis never sees the JS side — this include bridges that gap.
398
+ include: ['element-plus'],
399
+ },
391
400
  server: {
392
401
  open: true,
393
402
  ...(port != null && { port }),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bndynet/vue-site",
3
- "version": "0.1.6",
3
+ "version": "0.1.8",
4
4
  "type": "module",
5
5
  "description": "A configurable Vue 3 site framework with sidebar navigation, markdown rendering, and theme switching.",
6
6
  "repository": {