You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "kgabryje (via GitHub)" <gi...@apache.org> on 2024/07/31 16:34:50 UTC

[PR] perf: Lazy load React Ace [superset]

kgabryje opened a new pull request, #29796:
URL: https://github.com/apache/superset/pull/29796

   ### SUMMARY
   `ace-builds` was 1 of the largest libraries in our bundle. It was always fetched when opening a dashboard even though it's only used in dashboard's edit mode (if there are markdown components), SQL lab, and SQL Editor popover in Explore.
   This PR implements lazy loading that library.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   Notice that we no longer fetch a 1.3MB chunk when opening a dashboard
   
   Before:
   
   <img width="837" alt="Screenshot 2024-07-31 at 16 36 23" src="https://github.com/user-attachments/assets/5ffe5fdf-989d-4933-acde-5ceb8a96c5df">
   
   After:
   
   <img width="837" alt="Screenshot 2024-07-31 at 18 17 22" src="https://github.com/user-attachments/assets/8e939703-77cc-4265-9d38-10ef949bb27f">
   
   
   ### TESTING INSTRUCTIONS
   1. Open a dashboard
   2. Verify that the chunk containing ace-builds is not fetched initially
   3. Open edit mode and try to edit a markdown component - verify that it works fine
   4. Open SQL Lab - verify that SQL editor works fine
   5. Open a chart and metrics edit popover - verify that SQL editor works fine
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] perf: Lazy load React Ace [superset]

Posted by "mistercrunch (via GitHub)" <gi...@apache.org>.
mistercrunch commented on PR #29796:
URL: https://github.com/apache/superset/pull/29796#issuecomment-2261367359

   Oh nice! Looks like this will positively impact the Explore page loading times positively too


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] perf: Lazy load React Ace [superset]

Posted by "kgabryje (via GitHub)" <gi...@apache.org>.
kgabryje merged PR #29796:
URL: https://github.com/apache/superset/pull/29796


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org