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

feat(axe.sansPolyfills): add axe version without polyfills #2067

Closed
wants to merge 3 commits into from

Conversation

straker
Copy link
Contributor

@straker straker commented Feb 27, 2020

Reduces the file size of axe from 1.1 MB to 905 KB unminified, and 471 KB to 396 KB minified.

We had discussed moving to core-js for our polyfills, but decided against it in another pr due to the file size increase. However, since we have a version without polyfills, we can use that version in our extensions which do not need the polyfills. (FYI, core-js polyfills only add .05 MB to axe.js, going from 1.06 MB to 1.11 MB)

Also, I'm not sure why we were bothering to beautify the code before minifying it. Our code is already run through prettier so we don't need to beautify that, which means we were beautifying the babel output which seems unnecessary since we're never debugging that code. I also simplified the uglify code options.

Closes issue: #1935

Reviewer checks

Required fields, to be filled out by PR reviewer(s)

  • Follows the commit message policy, appropriate for next version
  • Code is reviewed for security

@straker straker requested a review from a team as a code owner February 27, 2020 19:19
@straker
Copy link
Contributor Author

straker commented Mar 3, 2020

@WilcoFiers for v4, should we just make axe.js default not have polyfills and then tell IE 11 users how to polyfill what we need? Something like https://polyfill.io/v3/ or brining in core-js themselves?

@stephenmathieson
Copy link
Member

I'm in favor of delaying this until v4 and shipping without any polyfills by default.

@WilcoFiers
Copy link
Contributor

This saves a lot less space then I thought it would.

@straker straker closed this Mar 4, 2020
@WilcoFiers WilcoFiers deleted the sansPolyfills branch July 17, 2020 09:36
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