From c92e593a16e03644a1bd58d914a54fcc97dbc144 Mon Sep 17 00:00:00 2001 From: Sebastian Martinez Date: Thu, 7 Sep 2023 21:26:40 +0200 Subject: [PATCH] Fix vite reloading during e2e tests The issue seems to have been linked to the fact that we triggers incorrect refresh through fsEvents. Even tough there are no changes on the local file system, it requests full reload after 1-2 min. Disabling fsEvents in the vite.config.ts prevents this to happen and per extension, avoid the problem. source: https://stackoverflow.com/a/75238360 Signed-off-by: Sebastian Martinez --- vite.config.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/vite.config.ts b/vite.config.ts index b899c424b..bcfde69c7 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -22,6 +22,10 @@ export default defineConfig({ server: { host: "localhost", port: 3000, + watch: { + // reference: https://stackoverflow.com/a/75238360 + useFsEvents: false, + }, }, resolve: { alias: {