File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -109,6 +109,11 @@ jobs:
109109 if : steps.changed.outputs.integrations != '[]'
110110 working-directory : website
111111 run : |
112+ # docusaurus-mdx-checker is a package that is not frequently updated. Its dependency katex sometimes ships a
113+ # broken ESM build, where a __VERSION__ placeholder is left unresolved, causing a ReferenceError at import time.
114+ # Node 22+ prefers ESM when available. We force CJS (CommonJS) resolution to use the working katex build.
115+ # This should be safe because docusaurus-mdx-checker and its dependencies provide CJS builds.
116+ export NODE_OPTIONS="--conditions=require"
112117 npx docusaurus-mdx-checker -v || {
113118 echo ""
114119 echo "For common MDX problems, see https://docusaurus.io/blog/preparing-your-site-for-docusaurus-v3#common-mdx-problems"
You can’t perform that action at this time.
0 commit comments