Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(gatsby-plugin-mdx): Use getNodesByType for plugin transformation (#…
…22555) Since getSourcePluginsAsRemarkPlugins is called on every MDX file, the getNodes call became expensive at scale with thousands of MDX files. This was encountered when attempting to find underlying issues for #22521. @pvdz had a hunch that node traversal may be a culprit. This doesn't fully address all underlying performance issues but is a quick win. 8k MDX pages: 440s => 350s 16k MDX pages: 1100s => 750s
- Loading branch information
Showing
2 changed files
with
6 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters