-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Include/exclude config for bun run --watch
#5278
Comments
Yeah Bun's hot-reloading would be amazing if we could reload on HTML/CSS/markdown etc changes, rather than just JS in the module graph. I've got a websocket-based browser reload mechanism working, but it doesn't trigger when the files that matter change 😅 Deno's
|
I'm using Fastify and Vite for a new project. Having the possibility to exclude files from being watched would solve this imo. |
Hi, are there any interest about this issue ? Basically I'm at the same as @jens-ox, this would allow full hot reload capability with SSR |
As of v1.1.27 Bun will hot-reload on arbitrary file changes if you https://bun.sh/blog/bun-v1.1.27#watch-arbitrary-file-types-in-watch-and-hot It would still be nice to be able to exclude files from the watcher though |
What is the problem this feature would solve?
I would like to propose improvements to the
bun run --watch
command in order to make it more versatile and applicable to a wider range of use cases.E.g. prevent hard/soft restart when
tsx
files changed.What is the feature you are proposing to solve the problem?
Include/exclude glob config for watch mode
1.
bunfig.toml
2. CLI
bun run --watch --watch-includes=**/*.ts --watch-excludes=**/*.tsx
What alternatives have you considered?
nodemon
The text was updated successfully, but these errors were encountered: