Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: capture watch mode when called via the Rollup API (#384)
- `process.env.ROLLUP_WATCH` is only set when using the CLI - when using watch mode through the Rollup API (https://rollupjs.org/guide/en/#rollupwatch), this is not set - but since Rollup 2.14.0 (https://github.com/rollup/rollup/blob/master/CHANGELOG.md#2140), `this.meta.watchMode` is available - still check the env variable for backward-compat on older Rollup versions - notably, this is needed to test watch mode, since the tests are done via the Rollup API
- Loading branch information