Skip to content

Babel 6 upgrade - #683

Merged
developit merged 11 commits into
preactjs:masterfrom
gpoitch:babel6
Jul 11, 2017
Merged

developit merged 11 commits into
preactjs:masterfrom
gpoitch:babel6

Conversation

@gpoitch

@gpoitch gpoitch commented May 2, 2017 •

Copy link
Copy Markdown
Contributor

Building & testing working 100%.
Diff with old babel 5 output: https://www.diffchecker.com/VmO4dPJb
Output is identical to babel 5 (via 1 added codemod)

TODO:

  • Investigate why code coverage dropped
  • Restore gzip size, which went up slightly. I think this is because of the renamed let variables, which has no effect on the minified size, but being minified to different characters effects the gzip size?

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage decreased (-1.6%) to 98.351% when pulling cae8167 on gdub22:babel6 into 9001436 on developit:master.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage decreased (-1.7%) to 98.347% when pulling d678932 on gdub22:babel6 into 9001436 on developit:master.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage decreased (-1.7%) to 98.347% when pulling 6405efe on gdub22:babel6 into 9001436 on developit:master.

@xtuc

xtuc commented May 2, 2017 •

Copy link
Copy Markdown

Awesome 👍

Note that Babel 7 will be released soon and the upgrade should be easy in Preact's case.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 2354686 on gdub22:babel6 into 9001436 on developit:master.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 6b09fa9 on gdub22:babel6 into 9001436 on developit:master.

@gpoitch

gpoitch commented May 3, 2017

Copy link
Copy Markdown
Contributor Author

@developit this is good to go for review now

let j = api.jscodeshift;
let code = j(file.source);

code.findVariableDeclarators().filter(d => /^_i/.test(d.value.id.name)).renameTo('i');

@developit developit May 25, 2017 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Slight chance this might collide with other variables, right? It's okay if it does, just wasn't sure if it was doing scope analysis to avoid it.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes it would be possible if someone added a var with that prefix. No scope analysis.

I personally wouldn't add this mod at all. I just wanted to make the output identical.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 8d25530 on gdub22:babel6 into 5b6c21b on developit:master.

@developit

Copy link
Copy Markdown
Member

So excited to have this at size parity! 💃

@coveralls

Copy link
Copy Markdown

Coverage Status

Changes Unknown when pulling d7f865b on gdub22:babel6 into ** on developit:master**.

@treshugart

treshugart commented May 30, 2017 •

Copy link
Copy Markdown

I'm in the process of adding custom element support (<CustomElement />) and need the fixed class transpile that Babel 6 gives us. Anything I can do to help move this along, please let me know!

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 5a5cc80 on gdub22:babel6 into b80bec3 on developit:master.

@coveralls

Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 100.0% when pulling 11235d7 on gdub22:babel6 into d213b08 on developit:master.

@developit developit modified the milestone: 8.2.0 Jun 22, 2017
@developit
developit merged commit c10e19a into preactjs:master Jul 11, 2017
@xtuc

xtuc commented Jul 11, 2017

Copy link
Copy Markdown

Congrats 💃

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.

5 participants