enableAutoTrack static method

void enableAutoTrack(
  1. int autoTrackEventType, {
  2. Map<String, dynamic>? autoTrackEventProperties,
  3. String? appId,
})

Enable the auto tracking function with properties

autoTrackEventType Indicates the type of the automatic collection event to be enabled

autoTrackEventProperties auto track event properties

appId It is used in multi-instance scenarios. If there is only one instance, it is recommended not to pass

Implementation

static void enableAutoTrack(int autoTrackEventType,
    {Map<String, dynamic>? autoTrackEventProperties, String? appId}) {
  ThinkingAnalyticsAPI? instance = _getInstanceByAppId(appId);
  instance?.enableAutoTrackWithProperties(
      autoTrackEventType, autoTrackEventProperties);
}