Add some output
This commit is contained in:
parent
96b093fcf5
commit
f293cbd05f
1 changed files with 3 additions and 0 deletions
|
@ -104,13 +104,16 @@ async function rebuild() {
|
||||||
'sourcemap.json',
|
'sourcemap.json',
|
||||||
JSON.stringify(sourcemap, null, 2),
|
JSON.stringify(sourcemap, null, 2),
|
||||||
)
|
)
|
||||||
|
console.log('Sourcemap rebuilt.')
|
||||||
}
|
}
|
||||||
|
|
||||||
for (const root of SOURCE_ROOTS) {
|
for (const root of SOURCE_ROOTS) {
|
||||||
fs.watch(root, { recursive: true }, () => {
|
fs.watch(root, { recursive: true }, () => {
|
||||||
|
console.log(`Detected change in ${root}, rebuilding sourcemap...`)
|
||||||
sourcemapCache.delete(root)
|
sourcemapCache.delete(root)
|
||||||
rebuild()
|
rebuild()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
console.log('Rebuilding sourcemap...')
|
||||||
rebuild()
|
rebuild()
|
||||||
|
|
Loading…
Reference in a new issue