Commit fd2f55d
committed
fix: add default resolve conditions to prevent server-side Svelte resolution
The `vite-plugin-solid` config hook sets `resolve.conditions` to
`['solid', 'development']`, replacing Vite's defaults which include
`browser` and `module`. Without `browser`, Svelte's package exports
resolve to `index-server.js` instead of `index-client.js`, causing
`mount(...)` to throw "not available on the server" in the browser.
Add `['module', 'browser', 'development']` to the base Vite config so
framework plugins append to these defaults rather than replacing them.
https://claude.ai/code/session_01DyKgnqFPLT1z1z4ewaEtMT1 parent 5b7a648 commit fd2f55d
2 files changed
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
141 | | - | |
| 141 | + | |
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
288 | 288 | | |
289 | 289 | | |
290 | 290 | | |
| 291 | + | |
291 | 292 | | |
292 | 293 | | |
293 | 294 | | |
| |||
0 commit comments