rollup-watch
Watch files for changes and perform incremental rebuilds with Rollup
This package has a good security score with no known vulnerabilities.
Community Reviews
Deprecated Package with Security and Maintenance Concerns
When I used this in legacy projects, the watch implementation was basic but functional. However, the error handling is minimal and doesn't provide useful context when file watching fails. There's no input validation on watch paths, which could potentially be exploited if user input reaches the configuration. The library doesn't handle symlinks securely and can follow them unexpectedly.
The biggest practical issue is dependency rot. Running npm audit shows transitive dependencies with known vulnerabilities that will never be patched. Modern Rollup projects should use the built-in watch mode (rollup -w) or rollup-plugin-serve, which are actively maintained and have proper security support.
Best for: Maintaining legacy projects where migration effort isn't justified (only until dependencies force an upgrade).
Avoid if: You're starting any new project or care about security updates and supply chain risk.
Deprecated Package - Use Rollup's Built-in Watch Mode Instead
When I initially tried this package before realizing it was deprecated, the setup was confusing because the documentation doesn't clearly indicate its obsolete status. The API itself was straightforward - you'd pass your Rollup config and get file watching - but error messages when things went wrong were minimal. The package would silently fail or throw cryptic errors when module resolution failed.
The migration path is simple: just use Rollup's native watch API (`rollup.watch()`) which has better error handling, active maintenance, and clearer documentation. The built-in watch mode provides the same functionality with better performance and integration.
Best for: Legacy projects already using it that haven't migrated to modern Rollup versions.
Avoid if: You're starting any new project or using Rollup 0.50 or later, which includes native watch functionality.
Deprecated Package - Use Rollup's Built-in Watch Mode Instead
The API itself was straightforward when it was relevant - you'd import the watcher, pass your Rollup config, and listen for events. However, the lack of TypeScript definitions, outdated dependencies, and absence of modern JavaScript features make it painful to work with today. Error messages are basic and don't provide the helpful context you'd expect from current tooling.
The migration path is clear: remove this package and use Rollup's native `rollup.watch()` API instead. The modern API is better documented, actively maintained, and provides superior type safety. There's simply no reason to use rollup-watch in any new or actively maintained project.
Best for: Legacy projects that haven't yet migrated to modern Rollup versions.
Avoid if: You're starting a new project or can upgrade to Rollup v0.60 or later (which you should).
Sign in to write a review
Sign In