Skip to content

Optimize MFE Performance #138

Closed
Closed
@ghassanmas

Description

@ghassanmas

Area of improvment in MFEs can be:

The what

  • Reudcing the file sizes:
    • Elmenate unused CSS (The size of css file is around 1MB, for the learning)
    • Reduce app.hash.js file size (its around 0.5MB)
    • The requried depencs chunk is around 2.5MB (For example checking the learning build, it seems that all users are going JS code realted the frontend-lib-speica-exams, no matter if or not they gonna use it)
    • Can we use preact It's a light weight alternative to react.js
    • Check for unsued JS code
    • Reduce CSS file (An example feat: reduce size CSS output file frontend-build#266 Still need futher testing though)
    • Check for unsued Assets
      • Do paragon icons have all to be preloaded, checking bundle analyzer (its around 0.5MB)
      • Are Paragon componenets being Tree Chaked

The How (Not an exlusive list,)

  • Do you utilize Code Splitting/Dynamic Import when is an opportunity for, this can be ensuring code logic for uncommon use cases is only loaded when it needs to, Here are some examples which might be already taken account of
  • Use Webpack plugins to reduce code size
  • Serve encoded/zipped version of assets file (This has be done with tutor form the latest release)
  • Can we have a common assets than loads from CDN from common depends:
    • This solution might be optimize perforamce when going to one MFE but rather when user browse between them (Which somehting very common I assume_)
    • This might go in line with Discovery: Faster build tool #126, since in theoray we shouldn't need to compile the commons aseets for every MFE
    • Another way of doing this can be Module Fedeartion

How to test

Other Notes

Metadata

Metadata

Assignees

No one assigned

    Labels

    epicLarge unit of work, consisting of multiple tasks

    Type

    No type

    Projects

    Status

    Closed

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions