Problem
skills/.curated/react/references/conc-concurrent-safe.md recommends an empty-dependency Effect with a ref-guarded body for "once on mount" intent.
In development Strict Mode, React deliberately runs an extra setup → cleanup → setup cycle. A ref guard can suppress the second setup after cleanup, leaving the external synchronization torn down.
Proposed correction
Keep this change narrowly scoped to the canonical-resolution paragraph:
- synchronization with external systems uses an Effect with complete dependencies and cleanup that mirrors setup;
- app initialization runs at module scope or in a framework boot hook; and
- Effects remain correct across setup → cleanup → setup instead of suppressing remount setup with a ref guard.
Official references:
Problem
skills/.curated/react/references/conc-concurrent-safe.mdrecommends an empty-dependency Effect with a ref-guarded body for "once on mount" intent.In development Strict Mode, React deliberately runs an extra setup → cleanup → setup cycle. A ref guard can suppress the second setup after cleanup, leaving the external synchronization torn down.
Proposed correction
Keep this change narrowly scoped to the canonical-resolution paragraph:
Official references: