Skip to content

Commit 16bb8e3

Browse files
committed
fix: add proper JSON formatting to source map writes for Windows compatibility
1 parent 3027559 commit 16bb8e3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

webview-ui/src/vite-plugins/sourcemapPlugin.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,8 @@ export function sourcemapPlugin(): Plugin {
8888
})
8989
}
9090

91-
// Write back the updated source map
92-
fs.writeFileSync(mapPath, JSON.stringify(mapContent))
91+
// Write back the updated source map with proper formatting
92+
fs.writeFileSync(mapPath, JSON.stringify(mapContent, null, 2))
9393
console.log(`Updated source map for ${jsFile}`)
9494
} catch (error) {
9595
console.error(`Error processing source map for ${jsFile}:`, error)

0 commit comments

Comments
 (0)