sad refactor: use legacy devDepsScanner for component HMR

This commit is contained in:
bholmesdev 2022-06-23 18:45:15 -04:00
parent 3d52d8c2ac
commit 694b3f024b

View file

@ -58,6 +58,11 @@ export async function createVite(
define: {
'import.meta.env.SITE': astroConfig.site ? `'${astroConfig.site}'` : 'undefined',
},
// fixes HMR for static components
// TODO: remove!
legacy: {
devDepsScanner: true,
},
server: {
hmr:
process.env.NODE_ENV === 'test' || process.env.NODE_ENV === 'production'