🧪 Fail the build when the client bundle carries the server runtime

The postbuild step now recreates the tracked build placeholder and checks
that the client bundle holds Svelte's browser runtime and the service
worker registration, so a wrong export condition cannot ship unnoticed.
This commit is contained in:
2026-12-02 19:05:47 +01:00
parent d804699ad0
commit 2c2c7a97c6
2 changed files with 27 additions and 1 deletions
+1 -1
View File
@@ -6,7 +6,7 @@
"scripts": {
"dev": "vite dev",
"build": "vite build",
"postbuild": "node -e \"require('fs').mkdirSync('build',{recursive:true});require('fs').writeFileSync('build/.gitkeep','')\"",
"postbuild": "node scripts/postbuild.mjs",
"preview": "vite preview",
"test": "vitest run",
"test:watch": "vitest",