capsules plus a la ligne, site name MATHALLO wysiwyg style

This commit is contained in:
2026-09-15 10:27:25 +02:00
parent 0d84a8fc22
commit 41b2abd408
9 changed files with 55 additions and 7 deletions
+23
View File
@@ -0,0 +1,23 @@
import { createServer, build } from 'vite'
// Build watcher : écrit les fichiers dist sur disque en continu
const watcher = await build({
build: { watch: {} },
})
// Dev server : HMR sur localhost:5173
const server = await createServer()
await server.listen()
console.log('\n HMR actif + dist générés en watch\n')
const shutdown = async () => {
await Promise.allSettled([
watcher.close(),
server.close(),
])
process.exit(0)
}
process.on('SIGINT', shutdown)
process.on('SIGTERM', shutdown)