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

Use loose mode on Babel stage-0 plugins #146

Closed
wants to merge 1 commit into from

Conversation

JayCanuck
Copy link
Member

Specifically needed for the stage-3 plugin for class properties to fix support for mobx and potentially other 3rd party software. Fixes the issue observed at enactjs/agate-apps#45 (comment)

Enact-DCO-1.0-Signed-off-by: Jason Robitaille jason.robitaille@lge.com

Specifically needed for the stage-3 plugin for class properties to fix support for mobx and potentially other 3rd party software.
@@ -22,7 +22,7 @@ module.exports = {
modules: false
}
],
'@babel/preset-stage-0',
['@babel/preset-stage-0', {loose: true}],
Copy link
Contributor

@webOS101 webOS101 Sep 26, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure it's a good idea to go loose on all of the stage 0 presets. It's not recommended to use loose, though it will produce faster code... Can we be more targeted? It seems we only need loose class properties. See mobxjs/mobx#1352 regarding some babel 7 issues. Is Mobx support more important than keeping close to the standard?

Copy link
Member Author

@JayCanuck JayCanuck Sep 26, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the webpack 4 work we are specific and only target the class properties plugin (as presets are gone then). Unless we want larger scale changes in cli, we can take this change as a temporary fix until webpack 4 is merged, or wait until the webpack 4 pr goes in. Moreso upto you guys since it only affects mobx for us so far.

@lishammel
Copy link

closing out - @JayCanuck says this PR is no longer needed

@lishammel lishammel closed this Oct 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants