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

Performance imrovements: webpack config(added chunks), code refactor #883

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ioay
Copy link
Contributor

@ioay ioay commented Dec 13, 2023

### JUST FOR TESTING PURPOSE! DO NOT REVIEW!

Issues connected

Resolves: #881

What has been done

  • Bundle splitting (before the size of one file: bundle.js had 2.3MB, currently splitting bundle sizes do not exceed 320KB)
  • Added minification
  • Removed devtool source-map from production build
  • Removed unused packages
  • Refactoring initializing app:
    • divided components to increase readability and performance by loading only necessary modules on the startup
    • declared .webm module(modern video format) to use instead .mp4 format(currently size of portal background video is 1.9MB, previously we loaded ~34.3MB on app init)
    • added pre-connection support for external libraries
    • changed .png to modern image format: .webp (large reduction in the size of loaded files)
    • extracted global styles to App file (out of providers)
    • moved posthog config to a standalone file
    • increased Accessibility

Summary & thoughts

Reflect slows down significantly applications a lot at the beginning.
We must modify it so that it loads only when needed - not immediately after loading the application.

Testing

  • Test 1

Screenshots / images / videos

Previous budle.js & Google Lighthouse results:
Screenshot 2023-12-18 at 15 29 47

Screenshot 2023-12-18 at 15 35 24

Current bundles & Google Lighthouse results:
Screenshot 2023-12-18 at 15 26 37

Screenshot 2023-12-18 at 15 34 36

Google Lighthouse results when reflect disabled:
Screenshot 2023-12-18 at 13 02 42

Copy link

netlify bot commented Dec 13, 2023

Deploy Preview for taho-development ready!

Name Link
🔨 Latest commit 5dd936e
🔍 Latest deploy log https://app.netlify.com/sites/taho-development/deploys/6580db612cf0a4000863bdd9
😎 Deploy Preview https://deploy-preview-883--taho-development.netlify.app/
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@ioay ioay force-pushed the performance_improvements branch 4 times, most recently from 80071cb to 7b20917 Compare December 14, 2023 00:16
@ioay ioay self-assigned this Dec 14, 2023
@ioay ioay force-pushed the performance_improvements branch 8 times, most recently from ba3b4d0 to bf83c05 Compare December 14, 2023 14:39
@ioay ioay changed the title Performance imrovements: webpack config(uglify & chunks), code refactor Performance imrovements: webpack config(added chunks), code refactor Dec 14, 2023
@ioay ioay force-pushed the performance_improvements branch 15 times, most recently from 1f5d452 to a76a515 Compare December 17, 2023 21:50
@ioay ioay force-pushed the performance_improvements branch 28 times, most recently from f7ea7dd to b2a8b5f Compare December 18, 2023 23:46
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.

Inestigation: performance issue in the dapp
1 participant