[flags] Cleanup enableFragmentRefsScrollIntoView feature flag #37574

Open
javache opened 10:15am on September 10, 2026 wants to merge 91 Ξ” into facebook/react main from
cleanup/enable-fragment-refs-scroll-into-view
javache authored
of work during September 10
Diff Delta:
91
About 17 Diff Delta/hour
Classified as:  Bug Fix, General

javache's Description of Work


[!NOTE]
Stacked on #37573. That PR's commit shows up in the diff here until it lands; only the second commit is part of this change.


Summary

Inlines the enabled branch of enableFragmentRefsScrollIntoView and removes the flag from ReactFeatureFlags and all of its forks.

This is a DOM-only change. The flag's only consumer was ReactFiberConfigDOM, where it guarded the definition of FragmentInstance.prototype.scrollIntoView, so the code change is a plain unwrap and dedent of that one block with no logic edits.

The flag was declared false in the native forks, but those declarations were inert: Fabric never defined scrollIntoView on FragmentInstance at all, so removing the flag does not change any native behavior.

The one combined gate, @gate enableFragmentRefsTextNodes && enableFragmentRefsScrollIntoView, was reduced to @gate enableFragmentRefsTextNodes rather than dropped.

How did you test this change?

yarn lint, yarn prettier-check, and yarn flow for dom-node, dom-browser, and fabric all pass.

Full test suite run across experimental, stable, www-modern, www-classic, and xplat, with both --variant settings, plus --persistent. The remaining failures (Fizz / Flight / FrameScheduling / ClassEquivalence) are pre-existing: I diffed the individual failing test names against the parent commit and they are identical.

Building updated commit group diff...
20 total changed files
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...