LocalEventTrackerService
The EventTrackerService used by TrackScreenView, TrackOnLifecycleEvent, rememberTracker and trackImpression.
Provide it once, at the root of your Compose tree, from wherever your app gets its tracker:
setContent {
CompositionLocalProvider(LocalEventTrackerService provides tracker) {
App()
}
}Content copied to clipboard
Reading it without a provider throws. The helpers do not read it in previews or in the layout inspector, so those work without a provider.