-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Running react-redux with Babel 6 #212
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
Conversation
"stage": 0, | ||
"loose": "all" | ||
"presets": ["es2015", "stage-0", "react"], | ||
"plugins": [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why we need to add those plugins? They should already included in presets.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Refactored the code. Thanks. 👍
typeof SourceClass.prototype[key] === 'function' | ||
).forEach(key => { | ||
if (key !== 'render') { | ||
if (key !== 'render' && key !== 'constructor') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is modifications in this file relative to babel6?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes.
+1 |
Running react-redux with Babel 6
@gaearon Do we want loose mode for IE8? React-Redux previously used it but this PR does not. |
How is loose mode related to IE8? I thought it was about improving perf. |
Either way I'd prefer adding loose mode back :-). I don't know how to do it though. |
When not in loose mode Babel uses Object.defineProperty. You are right about the perf too though. There is a preset for loose mode. The Babel 6 PR in redux has it. |
Can you please fix it here? |
Yep, give me a minute. |
@ellbee Any other work there, or can I release 4.0.1 that doesn't have |
@gaearon Go for it. |
Out with 4.0.1 👍 |
Refs #206