-
-
Notifications
You must be signed in to change notification settings - Fork 223
Description
Describe the bug
The watcher in extension.ts and the fallbackwatcher in FallbackWatcher.ts both watch too many files. They ignore node_modules, but they do not ignore build output directories. This means for example for Sapper that any changes in __sapper__ are watched and the TS plugin adds them to the list of known files, which is wrong.
To Reproduce
Start a Sapper project, change files and force rebuilds, see the number of files increase over time.
Expected behavior
Build directories are ignored
This could be done on a best-effor basis by
- always ignoring
__sapper__and.svelte(SvelteKit) - try to read a
.gitignorefile in the root of the opened workspace and ignore file changes in all those listed paths
I'm not sure we can completely transform this into a glob though, because the glob DSL is very limited. We might need to watch all files either way but filter out the events that come from the watcher based on the .gitignore.