Conversation
There was a problem hiding this comment.
Pull request overview
Updates the project’s file-watching stack by upgrading chokidar from v3 to v5 (which removes glob-pattern support) and adjusts the dev-server/watchFiles behavior, tests, and migration docs accordingly.
Changes:
- Bump
chokidardependency to^5.0.0and update the lockfile accordingly. - Refactor
Serverwatcher setup to async-importchokidarand await watch setup during initialization. - Update
watchFilese2e test logic and add migration documentation for the glob-pattern breaking change.
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/e2e/watch-files.test.js | Switches from chokidar glob patterns to pre-expanded file lists using fs.promises.glob(). |
| src/types.ts | Aligns chokidar type imports with newer chokidar typings (ChokidarOptions). |
| src/server.ts | Uses memoized async import of chokidar and makes watcher setup async/awaited. |
| rslib.config.ts | Removes chokidar from externals, affecting bundling behavior. |
| package.json | Updates chokidar version to ^5.0.0. |
| pnpm-lock.yaml | Updates resolved chokidar + dependency graph for v5. |
| docs/migrate-v1-to-v2.md | Documents chokidar v5 upgrade and the removal of glob-pattern support, with suggested migration approaches. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request performs a significant upgrade of the Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request updates chokidar from v3 to v5, which is a breaking change as it drops support for glob patterns. The changes include updating the dependency, documenting the breaking change with migration paths, and adjusting the server implementation and tests to align with the new version. My review focuses on the correctness of these changes. I've pointed out a potential issue with the build configuration regarding chokidar as an external dependency and suggested an improvement to the migration documentation to clarify a key difference between the suggested approaches.
Update chokidar dependency from v3 to v5, which drops glob pattern support.
Ref: webpack/webpack-dev-server#5374