Skip to content
This repository has been archived by the owner on Apr 13, 2023. It is now read-only.

Bundles #1769

Merged
merged 2 commits into from
Mar 8, 2018
Merged

Bundles #1769

merged 2 commits into from
Mar 8, 2018

Conversation

jbaxleyiii
Copy link
Contributor

@jbaxleyiii jbaxleyiii commented Mar 8, 2018

Sheesh, bundling is a mess in the js world today. This PR gives what I think is the best chance for future success?

This doesn't ship a flat bundle anymore, but looks like that may not be the best way forward. Instead we should work to get all Apollo projects to replicate the above so full tree shaking is possible. It will need to start with the Apollo Client repo for base utils, then include Apollo Link repo before this mjs will be particularly useful. This is part of the overall goals outlined here apollographql/apollo-link#537

EDIT: This didn't work. It breaks usage with CRA which is impacting graphql-js too facebook/create-react-app#4085

This PR reverts any mjs inclusion for now

@fabien0102
Copy link

mmmm, I've just try to update to 2.1.0-rc.1, the .mjs are still there and the build is still broken on CRA…

@tavelli
Copy link

tavelli commented Mar 15, 2018

just tested with 2.1.0-rc.3, working!

@jbaxleyiii jbaxleyiii restored the bundles branch March 16, 2018 15:27
@gaearon
Copy link

gaearon commented Apr 3, 2018

If your project is built with Create React App and not ejected, react-scripts@1.1.2 should fix this.
Here is how to upgrade:

https://github.com/facebook/create-react-app/releases/tag/v1.1.2

Otherwise you can apply a similar fix yourself in your project config. Cheers!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants