Skip to content
This repository has been archived by the owner on Jun 13, 2024. It is now read-only.

relative base fails #11

Open
wighawag opened this issue Dec 1, 2023 · 0 comments · May be fixed by #12
Open

relative base fails #11

wighawag opened this issue Dec 1, 2023 · 0 comments · May be fixed by #12

Comments

@wighawag
Copy link

wighawag commented Dec 1, 2023

Getting this issue when using

export default defineConfig({
  plugins: [sri()],
  base: "./",
});

vite v5.0.4 building for production...
✓ 3 modules transformed.
[vite:build-html] Cannot read properties of undefined (reading 'code')
✓ built in 70ms
error during build:
TypeError: Cannot read properties of undefined (reading 'code')
    at calculateIntegrityHashes (file:///home/wighawag/dev/github.com/wighawag/onboard-wallet/node_modules/.pnpm/@[email protected]/node_modules/@small-tech/vite-plugin-sri/index.js:46:31)
    at $.asyncForEach (file:///home/wighawag/dev/github.com/wighawag/onboard-wallet/node_modules/.pnpm/@[email protected]/node_modules/@small-tech/vite-plugin-sri/index.js:54:17)
    at transformIndexHtml (file:///home/wighawag/dev/github.com/wighawag/onboard-wallet/node_modules/.pnpm/@[email protected]/node_modules/@small-tech/vite-plugin-sri/index.js:62:21)
    at applyHtmlTransforms (file:///home/wighawag/dev/github.com/wighawag/onboard-wallet/node_modules/.pnpm/[email protected]/node_modules/vite/dist/node/chunks/dep-4RECYSE1.js:38687:27)
    at Object.generateBundle (file:///home/wighawag/dev/github.com/wighawag/onboard-wallet/node_modules/.pnpm/[email protected]/node_modules/vite/dist/node/chunks/dep-4RECYSE1.js:38506:32)
    at file:///home/wighawag/dev/github.com/wighawag/onboard-wallet/node_modules/.pnpm/[email protected]/node_modules/rollup/dist/es/shared/node-entry.js:18606:40
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
^C ELIFECYCLE  Command failed.

works with

export default defineConfig({
  plugins: [sri()],
});

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
1 participant