0.0.1 • Published 3 years ago

yach.open.report v0.0.1

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

yach.open.report

非知音楼环境打开的应用使用时长统计 jssdk

安装

yarn add yach.open.report

使用

浏览器使用

<!-- 引入 -->
<script src="node_modules/yach.open.report/lib/report.browser.js"></script>
<!-- 使用 -->
window.report.init(options);

npm 使用

// 引入
import report from "yach.open.report";
// 使用
report.init(options);

options

参数必填类型备注
appIdString应用 id
workCodeString用户 id
envString日志上报环境,online-生产环境、test-测试环境,默认值 online
showLogBoolean打开日志输出功能,默认值 false

示例

import report from "yach.open.report";

report.init({
    appId: 'xxxx',
    workCode: 'xxxx',
    env: 'online',
    showLog: false
});
0.0.1

3 years ago