TrackOnLifecycleEvent
Tracks event every time the host lifecycle reaches on. The default, ON_RESUME, is every time the screen becomes visible; ON_PAUSE or ON_STOP is every time the user leaves it. ON_DESTROY is not supported.
Does nothing in previews and in the layout inspector.