Skip to content
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

Document or build with babel-polyfill #125

Closed
modernserf opened this issue Jul 23, 2016 · 5 comments · Fixed by #238
Closed

Document or build with babel-polyfill #125

modernserf opened this issue Jul 23, 2016 · 5 comments · Fixed by #238

Comments

@modernserf
Copy link

This doesn't seem to include babel-polyfill. This would be fine for modern browsers except that Babel's generators depend on regeneratorRuntime, which is included in the polyfill. This needs to either be documented (i.e. "use babel-polyfill if you're supporting old browsers or using ES6 generators") or automatically included in the webpack build.

@mxstbr
Copy link
Contributor

mxstbr commented Jul 23, 2016

It's interesting because while I agree that generators should be supported, not many people will use them and the polyfill is quite a bit of code. I think documenting it might be the way to go here?

@vjeux
Copy link
Contributor

vjeux commented Jul 23, 2016

Is there a way to add regeneratorRuntime only if you use generators?

@gaearon
Copy link
Contributor

gaearon commented Jul 23, 2016

I thought this is how it worked but I'm probably wrong. Also worth looking at transform-runtime.

@insin
Copy link
Contributor

insin commented Jul 23, 2016

Discussion about this in #51

Ad-hoc reckons on the subject of auto-polyfilling, but based on having user config: https://gist.github.com/insin/711862bb578735c54c294d24bfb024ef

@gaearon
Copy link
Contributor

gaearon commented Jul 27, 2016

Generators should work out of the box with 0.2.0 alpha. #190

moos pushed a commit to moos/create-react-app that referenced this issue Feb 5, 2018
Add instructions to add to existing projects
@lock lock bot locked and limited conversation to collaborators Jan 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants