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

   ### SUMMARY
   
   First foundational step for #39890 (React 18 concurrent-feature adoption).
   
   Wraps the three React 18 root mounts in `<StrictMode>`:
   
   - `superset-frontend/src/views/index.tsx` (main app)
   - `superset-frontend/src/views/menu.tsx` (backend-rendered views' menu)
   - `superset-frontend/src/embedded/index.tsx` (embedded SDK)
   
   ### Why
   
   Per the React 18 docs, StrictMode's dev-mode double-invocation surfaces 
effect-cleanup and non-idempotent-render bugs that concurrent rendering will 
eventually expose at runtime. Turning it on now lets us catch those 
deliberately during local dev rather than have them appear later as "weird 
remount" or stale-state regressions.
   
   ### Scope notes
   
   - **Dev-only**. StrictMode is a no-op in production React builds; this PR 
has zero production impact.
   - **Test suite unaffected**. The custom RTL render wrapper at 
`spec/helpers/testing-library.tsx` does not enable StrictMode, so existing 
tests behave identically.
   - **No effect-cleanup audit in this PR.** The tracking issue's own guidance 
is "Expect a follow-up wave of small fixes once it's on. Plan for a cleanup 
pass; don't merge alongside other work." Any double-mount issues that surface 
during local dev should be triaged as discrete follow-ups against #39890.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   
   N/A — no UI change. Dev-mode console may now show second-invocation warnings 
for components with cleanup bugs; those are pre-existing latent issues to be 
fixed in follow-ups.
   
   ### TESTING INSTRUCTIONS
   
   1. `npm run dev` from `superset-frontend/`.
   2. Load any page (dashboard, explore, SQL Lab, embedded) — verify the app 
renders normally.
   3. Open the browser console; existing functionality should work. Expect 
possible new warnings from React about effects/refs in components that aren't 
yet idempotent — these are not regressions from this PR but are pre-existing 
issues StrictMode is now surfacing.
   4. Run `npm run build` to confirm production builds still succeed 
(StrictMode is stripped in prod).
   
   ### ADDITIONAL INFORMATION
   
   - [x] Has associated issue: #39890
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration
   - [ ] 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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to