React's injectInternals() calls hook.inject(renderer) before it will ever
invoke onCommitFiberRoot. When inject is missing, React's try/catch silently
bails and injectedHook stays null — our handler is never reached regardless
of how correctly onCommitFiberRoot is set up.
Fix: define inject() on the hook we create (returns a renderer ID and stores
the renderer in hook.renderers, matching the React DevTools spec). Also
patches inject onto any existing stub hook that lacks it, so third-party
minimal hooks don't silently block registration.
This is the root cause of the 'Static HTML page' false positive on apps
that don't have the React DevTools browser extension installed.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>