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

Reduce bundle size #1399

Merged
merged 6 commits into from
Apr 14, 2023
Merged

Reduce bundle size #1399

merged 6 commits into from
Apr 14, 2023

Conversation

lukaw3d
Copy link
Member

@lukaw3d lukaw3d commented Apr 14, 2023

Before:

$ yarn build
...
build/index.8cfd98b9.js                               ⚠️  6.07 MB    16.71s
Done in 28.17s.

After:

$ yarn build
...
build/index.073d82ed.js                               ⚠️  4.11 MB    11.88s
Done in 20.34s.

@lukaw3d lukaw3d requested a review from buberdds April 14, 2023 03:07
@github-actions
Copy link

github-actions bot commented Apr 14, 2023

🦙 MegaLinter status: ✅ SUCCESS

Descriptor Linter Files Fixed Errors Elapsed time
✅ ACTION actionlint 1 0 0.11s
✅ EDITORCONFIG editorconfig-checker 108 0 0.46s
✅ JAVASCRIPT eslint 2 0 0 5.93s
✅ JSON eslint-plugin-jsonc 1 0 0 1.03s
✅ JSON jsonlint 1 0 0.22s
✅ JSON npm-package-json-lint yes no 0.67s
✅ JSON prettier 1 0 0 0.55s
✅ JSON v8r 1 0 3.58s
✅ REPOSITORY checkov yes no 22.5s
✅ REPOSITORY git_diff yes no 0.0s
✅ TSX eslint 79 0 0 14.6s
✅ TYPESCRIPT eslint 2 0 0 7.73s
✅ YAML prettier 1 0 0 0.64s
✅ YAML v8r 1 0 2.22s
✅ YAML yamllint 1 0 0.26s

See detailed report in MegaLinter reports
Set VALIDATE_ALL_CODEBASE: true in mega-linter.yml to validate all sources, not only the diff

MegaLinter is graciously provided by OX Security

@lukaw3d
Copy link
Member Author

lukaw3d commented Apr 14, 2023

I also tried replacing @oasisprotocol/client-rt with @oasisprotocol/client-rt/dist/* but it isn't worth the hassle - it only saved ~50kb. And same for @ethereumjs/util.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Apr 14, 2023

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: ef32c86
Status: ✅  Deploy successful!
Preview URL: https://79c3ffb5.oasis-wallet.pages.dev
Branch Preview URL: https://lw-reduce-bundle.oasis-wallet.pages.dev

View logs

@codecov
Copy link

codecov bot commented Apr 14, 2023

Codecov Report

Merging #1399 (ef32c86) into master (d34da72) will increase coverage by 0.57%.
The diff coverage is 95.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1399      +/-   ##
==========================================
+ Coverage   83.20%   83.77%   +0.57%     
==========================================
  Files         146      146              
  Lines        3781     3988     +207     
  Branches      726      726              
==========================================
+ Hits         3146     3341     +195     
- Misses        635      647      +12     
Flag Coverage Δ
cypress 50.84% <ø> (-0.19%) ⬇️
jest 79.20% <95.66%> (+0.98%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/app/components/ErrorBoundary/index.tsx 0.00% <0.00%> (ø)
src/app/pages/E2EPage/index.tsx 41.93% <0.00%> (-8.07%) ⬇️
src/app/pages/HomePage/index.tsx 33.33% <0.00%> (-12.13%) ⬇️
src/app/components/AddEscrowForm/index.tsx 95.00% <100.00%> (+0.55%) ⬆️
src/app/components/AddressBox/index.tsx 100.00% <100.00%> (ø)
src/app/components/AlertBox/index.tsx 100.00% <100.00%> (ø)
src/app/components/AmountFormatter/index.tsx 100.00% <100.00%> (ø)
src/app/components/AnchorLink/index.tsx 100.00% <100.00%> (ø)
src/app/components/BuildPreviewBanner/index.tsx 100.00% <100.00%> (ø)
src/app/components/ButtonLink/index.tsx 100.00% <100.00%> (ø)
... and 64 more

... and 4 files with indirect coverage changes

@lukaw3d lukaw3d merged commit a81ecec into master Apr 14, 2023
@lukaw3d lukaw3d deleted the lw/reduce-bundle branch April 14, 2023 12:35
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.

2 participants