Commit f39a198
fix: ignore temp files in Vite watcher to prevent dev server crash (#3763)
## Summary
- Adds default `server.watch.ignored` patterns to the Fresh Vite plugin
config
- Ignores `*.tmp.*`, `*.timestamp-*`, editor swap files (`*.swp`,
`*.swo`, `*~`, `.#*`)
- Prevents a `watchFs` race condition on Linux where Deno tries to open
a short-lived file that was already deleted, crashing the dev server
with `NotFound: No such file or directory`
Users can still override or extend these patterns in their own
`vite.config.ts` since Vite merges config from plugins.
Closes #3585
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent b3cb5b5 commit f39a198
2 files changed
Lines changed: 43 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
94 | 111 | | |
95 | 112 | | |
96 | 113 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
0 commit comments