Skip to content
This repository has been archived by the owner on Jun 16, 2020. It is now read-only.

Latest commit

 

History

History
45 lines (31 loc) · 828 Bytes

README.md

File metadata and controls

45 lines (31 loc) · 828 Bytes

flutter_umeng_analytics

Flutter plugin for umeng:analytics

Usage

Init

import 'dart:io';

if (Platform.isAndroid)
  UMengAnalytics.init('Android AppKey',
           encrypt: true, reportCrash: false);
else if (Platform.isIOS)
  UMengAnalytics.init('iOS AppKey',
          encrypt: true, reportCrash: false);

Log page

initState() {
  super.initState();

  UMengAnalytics.beginPageView("home");
}

dispose() {
  super.dispose();

  UMengAnalytics.endPageView("home");
}

someFunction() {
  UMengAnalytics.logEvent("some click");
}

Getting Started

For help getting started with Flutter, view our online documentation.

For help on editing plugin code, view the documentation.