Spot why this 'deferred' analytics init still hurts app launch time and TTI.
Codejavascript
// index.js — app entry point
import { AppRegistry, InteractionManager } from 'react-native';
import App from './App';
import { name as appName } from './app.json';
import { initAnalytics, initCrashReporting, warmImageCache } from './startup';
// Move non-critical setup off the launch path so the UI paints first
InteractionManager.runAfterInteractions(() => {
initAnalytics();
initCrashReporting();
});
// Prewarm caches before the first frame
warmImageCache();
AppRegistry.registerComponent(appName, () => App);
The team wanted heavy startup work deferred so the first screen renders fast, but TTI barely improved. What is the bug?