fix: ignore globby from scanning monorepo node_modules for slowness fix#12129
fix: ignore globby from scanning monorepo node_modules for slowness fix#12129hariabinesh-l-4219 wants to merge 1 commit into
Conversation
|
Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
✅ [V2]Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify project configuration. |
slorber
left a comment
There was a problem hiding this comment.
We need:
- details about your monorepo setup, ideally a test repro (#12128 (comment))
- unit tests to cover edge cases and prevent regressions
- your CLA signature, or I can't merge
| async function readCategoriesMetadata(contentPath: string) { | ||
| const categoryFiles = await Globby('**/_category_.{json,yml,yaml}', { | ||
| cwd: contentPath, | ||
| ignore: ['**/node_modules/**'], |
There was a problem hiding this comment.
That could fix your specific problem, but also introduce problems in other site setups. For example, sites can decide to load their mdx docs from npm and have actual content in node_modules. We need to ensure we keep supporting this pattern with tests, because I'm not sure what's the behavior of Globby.
And we also want to migrate to tinyglobby or eventually native Node globbing API, which may behave differently too. (#11042)
Maybe this will work better? Without any test, it's hard to tell:
ignore: [${contentPath}//node_modules/'],`
Pre-flight checklist
Motivation
Test Plan
Test links
Deploy preview: https://deploy-preview-_____--docusaurus-2.netlify.app/
Related issues/PRs