Commit 558a9a9
authored
refactor: use magic-string for proper source maps in WASM fix (#234)
* refactor: use magic-string for proper source maps in WASM fix
Improve the WASM data URL fix to use magic-string for accurate source
map generation. This eliminates build warnings and ensures proper
debugging support.
- Replace string.replace() with MagicString.overwrite()
- Return both code and source map from renderChunk
- Uses existing magic-string dependency (via vite-plugin-dts)
* fix: remove non-null assertion and fix line endings
- Replace match.index! with proper undefined check
- Fix CRLF to LF line endings (biome format)1 parent 752cfaa commit 558a9a9
1 file changed
+20
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| 19 | + | |
| 20 | + | |
18 | 21 | | |
19 | 22 | | |
20 | 23 | | |
| |||
25 | 28 | | |
26 | 29 | | |
27 | 30 | | |
28 | | - | |
29 | | - | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
30 | 48 | | |
31 | 49 | | |
32 | 50 | | |
| |||
0 commit comments