auto-point 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +14 -0
  2. package/index.js +2 -0
  3. package/package.json +15 -0
package/README.md ADDED
@@ -0,0 +1,14 @@
1
+ <p align="center">AutoPoint</p>
2
+
3
+ <p align="center">以下简称AP</p>
4
+
5
+ ### document
6
+ **如何使用**
7
+
8
+ **Step 1**: 引入AP,可以通过npm i -S auto_point或<script src="https://www.gfb-js.com/GFB/gfb.js"></script>
9
+
10
+ **Step 2**: 引入对应框架的AP中间件(可选),中间件主要处理数据发送格式,开发人员可以手动实现中间间以实现自定义格式数据。
11
+
12
+ **Step 3**: 执行init()方法并传入配置参数,进行初始化。注意,AP应当在页面加载前进行初始化,否则将无法记录AP初始化前的浏览器动作。初始化完成后AP已经可以根据配置进行自动埋点动作收集和发送工作了。
13
+
14
+ **Step 4**: 初始化完成后可以根据需求,自行添加一些其他埋点信息,可以使用AP.add_point()方法添加一些自定义埋点数据,推荐使用object类型的数据,这些数据会与自动记录的埋点数据一起交给中间件处理之后发送给服务端。
package/index.js ADDED
@@ -0,0 +1,2 @@
1
+ 'use strict'
2
+ module.exports = require('./AP/auto_point.js')
package/package.json ADDED
@@ -0,0 +1,15 @@
1
+ {
2
+ "name": "auto-point",
3
+ "version": "0.0.1",
4
+ "description": "Automatic burying point",
5
+ "main": "index.js",
6
+ "files": [
7
+ "index.js",
8
+ "AP/*"
9
+ ],
10
+ "scripts": {
11
+ "test": "echo \"Error: no test specified\" && exit 1"
12
+ },
13
+ "author": "",
14
+ "license": "ISC"
15
+ }