NOTE: this is the recommended method for implementing you TWA application and the main purpose is to somehow attach Adtrace's life cycle into the app's life cycle.
ground rolls:
- add
permissions
andproguard
rolls anddependencies
! more info - create an
Application
class, create anAdTraceConfig
object (obviously with your own customizations) and feed it toAdTrace.onCreate(config)
. more info - have
AdTrace.onResume()
andAdTrace.onPause()
attached toApplication
. make sureonPuase
only triggered when app is off not sooner! more info