-
Notifications
You must be signed in to change notification settings - Fork 10.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compile the gatsby-module-loader with babel to fix IE #1891
Conversation
Deploy preview ready! Built with commit c414e02 |
Deploy preview ready! Built with commit c414e02 |
Hmmm... so these should be compiled as part of the normal Gatsby webpack build. Lemme go look into what's wrong. |
Yeah, they are being used *by* the webpack build though, which I think is
the issue.
|
Yeah we changed the babel config in a pretty big way recently which I think is the root of this. @jquense if you're around to offer some insight that'd be great. Looking into why webpack isn't compiling this code... |
Well that proved pretty easy — the loader code should be in https://github.com/gatsbyjs/gatsby/tree/master/packages/gatsby/cache-dir not in source… |
I'll PR that change. Thanks for helping point me in the right direction @danielfarrell! |
Oh hmmm I take it back. Webpack won't compile plugin code regardless of what we do... This does look like the right approach. Could you reopen the PR @danielfarrell? Or if you don't mind doing a bit more work — probably we should move this plugin to its own package where doing custom babel builds will be simpler. Then we can publish it as its own package and just make it a dependency of the Gatsby package. Would you like to take that on? |
Sure, I can take that on @KyleAMathews. |
I'm not sure this is the best way to fix #1839 but it should fix it. I am open to doing it a different way, just wanted to start a conversation and get a fix out there.