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

Bug 1297722 - Fix ES6 use in production #1807

Merged
merged 2 commits into from Aug 24, 2016
Merged

Conversation

wlach
Copy link
Contributor

@wlach wlach commented Aug 24, 2016

  • Use babel to make transpile ES6 code to ES5
  • Add a trivial use of the => function to make sure this actually works
    in production

This change is Reviewable

The uglify step of the grunt build won't work otherwise. Not crazy about the
way I did this, but I couldn't find any better way offhand.
@edmorley
Copy link
Contributor

edmorley commented Aug 24, 2016

Could we just drop usage of uglify instead? By how much does it actually reduce the end JS files after gzip?
Alternatively, is there a newer version of it/alternative package that is ES6 compatible?
It would be great to see the number of build steps that delay every deploy go down rather than up if possible :-) (they are the long pole for Heroku deploys particularly, since Heroku does a better job of caching the npm deps)

@wlach
Copy link
Contributor Author

wlach commented Aug 24, 2016

Yeah, I tried both those options (especially an uglify replacement) and couldn't find a recipe that worked. :( As far as I can tell, the world of node.js packaging is a complete and utter mess: at this point I've spent about 3 hours on this problem which is probably already more than I can justify. Once an es6-compatible version of uglify is released, we can always switch off the babel step.

@wlach wlach merged commit 0f936eb into mozilla:master Aug 24, 2016
@wlach wlach deleted the 1297722-2 branch August 24, 2016 20:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants