flutter 生成文件 Flutter整合文件

2021-10-13 09:30:54 字數 997 閱讀 9077

flutter整合文件

諸葛io移動統計支援flutter框架,以下為整合方法。

1.在專案中新增安裝外掛程式

在flutter專案的pubspec.yaml檔案中新增zhugeio依賴包

dependencies:

# zhugeio flutter plugin

zhugeio: ^1.0.1

執行flutter packages get 命令安裝外掛程式

flutter packages get

2.android端

android:name="android.permission.internet"/>

android:name="android.permission.access_network_state"/>

android:name="android.permission.access_wifi_state"/>

android:name="android.permission.read_phone_state"/>

2.2 新增專案依賴

dependencies );

注意:在新增事件屬性時,需注意事件屬性型別。如果事件屬性型別為「數值型屬性」,需要上傳資料時修改資料型別為「數值型」,並且在諸葛io後台埋點管理中修改為「數值型」。

4.2 繫結使用者資訊

zhugeio.identify('使用者id',)

4.3 開啟實時除錯

使用方法:在諸葛統計初始化之前呼叫如下**以開啟實時除錯,建議僅在測試裝置上開啟。

zhugesdk.getinstance().opendebug();

4.4 採集收入資料

記錄收入資料採集,需呼叫trackrevenue函式,自動記錄收入事件以及事件屬性;price(商品**)、productid(商品id)、productquantity(商品數量)、revenuetype(收入型別)為收入事件內建屬性,必傳項。

具體使用方法如下:

map product = ;

beego api自動生成文件

必須設定在 routers router.go 中,檔案的注釋,最頂部 apiversion 1.0.0 title mobile api description mobile has every tool to get any job done,so codename for the new mo...

Django 自動生成文件

老是忘 記錄下 coreapi pip install coreapi rest framework from rest framework.documentation import include docs urls urlpatterns url api include docs urls ti...

使用doxmate生成文件

主頁 3.安裝doxmate 開啟cmd 執行 npm install doxmate g 到此已安裝完成 在包含package.json readme.md的目錄下執行doxmate build 或者 doxmate build o output s wordpress 此目錄下 api.html...