You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Supposedly, the reason is in the quoted line below. We do not check where the export has default. So there is literally no way result of require can be a function in these cases. Yet every plugin that is not a function gets filtered out.
Some interoperable require function should be used. I confirmed locally that it works. Example:
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
Description
gatsby-plugin-mdx
fails to require plugins that have default exports.Steps to reproduce
gatsby-plugin-mdx
starter projectgatsby-remark-shiki
as a pluginAdd some code to markdown files
Run
gatsby develop
Expected result
Code should be formatted by
gatsby-remark-shiki
Actual result
Code is not formatted. No errors occur.
Environment
The text was updated successfully, but these errors were encountered: