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

fix webpack polyfills #9735

Merged
merged 2 commits into from
Jan 12, 2020
Merged

fix webpack polyfills #9735

merged 2 commits into from
Jan 12, 2020

Conversation

silverwind
Copy link
Member

webpack polyfills did not work because useBuiltIns: 'entry' expects a explicit core-js import. Changed it to 'usage' which does not require these explicit imports and polyfills based on browserslist.

As a result, the built index.js now went from 128kB to 192kB.

Ref: https://babeljs.io/docs/en/babel-preset-env#usebuiltins

webpack polyfills did not work because useBuiltIns: 'entry' expects a
explicit core-js import. Changed it to 'usage' which does not require
these explicit imports and polyfills based on browserslist.

As a result, the built index.js now went from 128kB to 192kB.

Ref: https://babeljs.io/docs/en/babel-preset-env#usebuiltins
@GiteaBot GiteaBot added the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Jan 12, 2020
@lafriks lafriks added the topic/build PR changes how Gitea is built, i.e. regarding Docker or the Makefile label Jan 12, 2020
@lafriks lafriks added this to the 1.12.0 milestone Jan 12, 2020
@silverwind
Copy link
Member Author

This should certainly be backported to 1.11.

@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Jan 12, 2020
@codecov-io
Copy link

Codecov Report

❗ No coverage uploaded for pull request base (master@a8d9a51). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #9735   +/-   ##
=========================================
  Coverage          ?   42.25%           
=========================================
  Files             ?      597           
  Lines             ?    78257           
  Branches          ?        0           
=========================================
  Hits              ?    33070           
  Misses            ?    41136           
  Partials          ?     4051

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a8d9a51...bbe0d74. Read the comment docs.

@sapk sapk merged commit a3977a3 into go-gitea:master Jan 12, 2020
@sapk
Copy link
Member

sapk commented Jan 12, 2020

Please send backport if possible.

silverwind added a commit to silverwind/gitea that referenced this pull request Jan 12, 2020
webpack polyfills did not work because useBuiltIns: 'entry' expects a
explicit core-js import. Changed it to 'usage' which does not require
these explicit imports and polyfills based on browserslist.

As a result, the built index.js now went from 128kB to 192kB.

Ref: https://babeljs.io/docs/en/babel-preset-env#usebuiltins

Co-authored-by: zeripath <[email protected]>
techknowlogick pushed a commit that referenced this pull request Jan 12, 2020
webpack polyfills did not work because useBuiltIns: 'entry' expects a
explicit core-js import. Changed it to 'usage' which does not require
these explicit imports and polyfills based on browserslist.

As a result, the built index.js now went from 128kB to 192kB.

Ref: https://babeljs.io/docs/en/babel-preset-env#usebuiltins
@zeripath zeripath added the backport/done All backports for this PR have been created label Jan 13, 2020
@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport/done All backports for this PR have been created lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. topic/build PR changes how Gitea is built, i.e. regarding Docker or the Makefile
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants