更新记录

0.1.3(2024-11-18) 下载此版本

  • 新增:uniapp 支持 小红书 SDK。
  • 小红书小程序 SDK 版本是 v0.14.3
  • 注意:uniapp 不支持 vue3 的小程序全埋点

0.1.1(2024-01-10) 下载此版本

  1. 新增
    • 支持 resetAnonymousIdentitygetIdentities 接口

0.1.0(2023-11-17) 下载此版本

微信小程序 SDK 更新到 1.20.2

查看更多

平台兼容性

Vue2 Vue3
App 快应用 微信小程序 支付宝小程序 百度小程序 字节小程序 QQ小程序
× × ×
钉钉小程序 快手小程序 飞书小程序 京东小程序
× × × ×
H5-Safari Android Browser 微信浏览器(Android) QQ浏览器(Android) Chrome IE Edge Firefox PC-Safari

神策 uni-app JSSDK 使用文档

1. 使用说明

本插件适用于 H5、APP、微信小程序、阿里小程序、百度小程序和头条小程序进行数据采集。

注:

  1. 对于 VUE3 的点击全埋点建议手动触发,默认不支持。
  2. APP 需集成 Native 端插件,否则无法进行 APP 端数据采集,具体集成可参考 神策 uni-app 原生插件

2. 使用方式

2.1. 引入及配置方式

2.1.1. 方案一: globalData 全局变量方式

App中设置:

 // 在 App.vue 或者 main.js 中设置 globalData.sensors 
<script> import sensors from '神策 uni-app JS SDK 路径/index.js';
    //同意隐私协议后调用进行 SDK 初始化
    sensors.init({
        server_url:'数据接收地址',
        show_log:false,//是否开启日志
        name:"sensors",
        global_properties:{ // 配置全局属性,所有上报事件属性中均会携带
            // property1: 'value1' 
        },,
        autoTrack:{//小程序全埋点配置
            appLaunch: true, // 默认为 true,false 则关闭 $MPLaunch 事件采集
            appShow: true, // 默认为 true,false 则关闭 $MPShow 事件采集
            appHide: true, // 默认为 true,false 则关闭 $MPHide 事件采集
            pageShow: true, // 默认为 true,false 则关闭 $MPViewScreen 事件采集
            pageShare: true, // 默认为 true,false 则关闭 $MPShare 事件采集
            mpClick: false, // 默认为 false,true 则开启 $MPClick 事件采集
            mpFavorite: true, // 默认为 true,false 则关闭 $MPAddFavorites 事件采集
            pageLeave: false // 默认为 false, true 则开启 $MPPageLeave事件采集
        },
        app:{// Android & iOS 初始化配置
            remote_config_url:"",
            flush_interval:15000,//两次数据发送的最小时间间隔,单位毫秒
            flush_bulkSize:100,//设置本地缓存日志的最大条目数,最小 50 条, 默认 100 条
            flush_network_policy:30, //设置 flush 时网络发送策略
            auto_track:0,  // 1 应用启动, 2 应用退出,3 应用启动和退出 默认 0
            encrypt:false,  //是否开启加密
            add_channel_callback_event:false,//是否开启渠道事件
            javascript_bridge:false, // WebView 打通功能
            android:{//Android 特有配置
                session_interval_time:30000,
                request_network:true,
                max_cache_size:32,     // 默认 32MB,最小 16MB
                mp_process_flush:false,//使用小程序 SDK 时,小程序进程是否可发送数据
            },
            ios:{//iOS 特有配置
                max_cache_size: 10000, //最大缓存条数,默认 10000 条
            }
        }
    });
    //弹窗 SDK 初始化,需在 init 之后调用
    sensors.popupInit({
        // 是否打印 log 日志
        show_log: true,
        // SFO 地址,由 SF 后端提供,sfo 在线服务地址
        api_base_url: '',
        enable_popup:true,//初始化后是否允许弹窗,若禁止则在需要弹窗时调用 enablePopup  @platform Android
        app_id: 'wx16ce2f6e06acd4d5'
    });

    export default {
        globalData:{
            sensors:sensors 
        },
        onLaunch: function() {
            console.log('App Launch')
        },
        onShow: function() {
            console.log('App Show')
        },
        onHide: function() {
            console.log('App Hide')
        } 
    }
</script> 

Page中设置

 // 在 Page 中通过 getApp().globalData.sensors 获取 
<script> 
    var sensors = getApp().globalData.sensors;
</script> 

2.1.2 方案二: import 方式

App中设置:

 // 在 App.vue 或者 main.js 中设置 
<script> import sensors from '神策 uni-app JS SDK 路径/index.js'; 
    sensors.init({
        server_url:'数据接收地址',
        show_log:false,//是否开启日志
        name:"sensors",
        global_properties:{ // 配置全局属性,所有上报事件属性中均会携带
            // property1: 'value1' 
        },
        autoTrack:{//小程序全埋点配置
            appLaunch: true, // 默认为 true,false 则关闭 $MPLaunch 事件采集
            appShow: true, // 默认为 true,false 则关闭 $MPShow 事件采集
            appHide: true, // 默认为 true,false 则关闭 $MPHide 事件采集
            pageShow: true, // 默认为 true,false 则关闭 $MPViewScreen 事件采集
            pageShare: true, // 默认为 true,false 则关闭 $MPShare 事件采集
            mpClick: false, // 默认为 false,true 则开启 $MPClick 事件采集
            mpFavorite: true, // 默认为 true,false 则关闭 $MPAddFavorites 事件采集
            pageLeave: false // 默认为 false, true 则开启 $MPPageLeave事件采集
        },
        app:{// Android & iOS 初始化配置
            remote_config_url:"",
            flush_interval:15000,//两次数据发送的最小时间间隔,单位毫秒
            flush_bulkSize:100,//设置本地缓存日志的最大条目数,最小 50 条, 默认 100 条
            flush_network_policy:30, //设置 flush 时网络发送策略
            auto_track:0,  // 1 应用启动, 2 应用退出,3 应用启动和退出 默认 0
            encrypt:false,  //是否开启加密
            add_channel_callback_event:false,//是否开启渠道事件
            javascript_bridge:false, // WebView 打通功能
            android:{//Android 特有配置
                session_interval_time:30000,
                request_network:true,
                max_cache_size:32,     // 默认 32MB,最小 16MB
                mp_process_flush:false,//使用小程序 SDK 时,小程序进程是否可发送数据
            },
            ios:{//iOS 特有配置
                max_cache_size: 10000, //最大缓存条数,默认 10000 条
            }
        }
    //弹窗 SDK 初始化,需在 init 之后调用
    sensors.popupInit({
        // 是否打印 log 日志
        show_log: true,
        // SFO 地址,由 SF 后端提供,sfo 在线服务地址
        api_base_url: '',
        enable_popup:true,//初始化后是否允许弹窗,若禁止则在需要弹窗时调用 enablePopup  @platform Android
        app_id: 'wx16ce2f6e06acd4d5'
    });
</script> 

Page中设置:

 <script> import sensors from '神策 uni-app JS SDK 路径/index.js'; </script> 

2.1.3 其他方式

这里介绍了两种使用全局变量的方式,其他方式也可以参考 uni-app 的文档 https://ask.dcloud.net.cn/article/35021 。

2.2. API

init

方法说明:设置和修改相关配置

适用平台:APP、H5、小程序

参数 类型 说明 是否必选
init object 相关配置项

代码示例:

    sensors.init({
        server_url:'数据接收地址',
        show_log:false,//是否开启日志
        name:"sensors",
        global_properties:{ // 配置全局属性,所有上报事件属性中均会携带
            // property1: 'value1' 
        },
        autoTrack:{//小程序全埋点配置
            appLaunch: true, // 默认为 true,false 则关闭 $MPLaunch 事件采集
            appShow: true, // 默认为 true,false 则关闭 $MPShow 事件采集
            appHide: true, // 默认为 true,false 则关闭 $MPHide 事件采集
            pageShow: true, // 默认为 true,false 则关闭 $MPViewScreen 事件采集
            pageShare: true, // 默认为 true,false 则关闭 $MPShare 事件采集
            mpClick: false, // 默认为 false,true 则开启 $MPClick 事件采集
            mpFavorite: true, // 默认为 true,false 则关闭 $MPAddFavorites 事件采集
            pageLeave: false // 默认为 false, true 则开启 $MPPageLeave事件采集
        },
        app:{//Android & iOS 特殊配置
            remote_config_url:"",
            flush_interval:1000,
            flush_bulkSize:100,
            flush_network_policy:30,设置 flush 时网络发送策略
            auto_track:0,  // 1 应用启动, 2 应用退出,3 应用启动和退出 默认 0
            encrypt:false,  //是否开启加密
            add_channel_callback_event:false,//是否开启渠道事件
            javascript_bridge:false, // WebView 打通功能
            android:{
                session_interval_time:30000,
                request_network:true,
                max_cache_size:32,     // 默认 32MB,最小 16MB
                mp_process_flush:false,//使用小程序 SDK 时,小程序进程是否可发送数据
            },
            ios:{
                max_cache_size: 10000, //最大缓存条数,默认 10000 条
            }
        }

track

方法说明:代码埋点方法,调用该接口采集自定义事件

适用平台:APP、H5、小程序

参数 类型 说明 是否必选
eventName String 事件名称
para Object 自定义属性
callback Function 事件发送成功回调 仅支持 H5

代码示例:

 sensors.track("eventName",{key : "value"}); 

getAppFlushInterval

方法说明:获取两次数据发送的最小时间间隔,单位毫秒

适用平台:Android、iOS

返回类型:number

getAppFlushBulkSize

方法说明:获取本地缓存日志的最大条目数

适用平台:Android、iOS

返回类型:number

getAppSessionIntervalTime

方法说明:获取 Session 时长

适用平台:Android

返回类型:number

getDistinctID

方法说明:获取当前用户的 distinctId

适用平台:Andorid、iOS、H5、小程序

返回类型:string

identify

方法说明:设置自定义匿名 ID

适用平台:Andorid、iOS、H5、小程序

参数 类型 说明 是否必选
id String 匿名 ID

getAnonymousID

方法说明:获取当前用户的匿名 ID

适用平台:Andorid、iOS、H5、小程序

返回类型:string

login

方法说明:登录,设置当前用户的登录 ID,触发用户关联事件

适用平台:Andorid、iOS、H5、小程序

参数 类型 说明 是否必选
id String 登录 ID

logout

方法说明:注销,清空当前用户的登录 ID

适用平台:Andorid、iOS、H5、小程序

bind

方法说明:用于多个用户 ID 关联时调用,第一个参数从详细的预置 id key 列表中获取,第二个参数为对应的关联用户 ID。 调用接口后,对应的 key 和 value 会缓存在本地,后续采集的事件,均包含缓存的 ID 信息。

适用平台:Andorid、iOS、H5、微信小程序 、支付宝小程序

参数 类型 说明 是否必选
name String id 键名
value String id 值

unbind

方法说明:用于多个用户 ID 取消关联时调用,第一个参数为取消关联的 key,第二个参数为对应的取消关联用户 ID。 调用接口后,会发送相关的解绑事件,同时会将本地缓存的 ID 信息中,对应的 key-value 清除(若存在)。

适用平台:Andorid、iOS、H5、微信小程序 、支付宝小程序

参数 类型 说明 是否必选
name String id 键名
value String id 值

loginWithKey

方法说明:用户登录时调用,第一个参数从详细的预置 id key 列表中获取,第二个参数为对应的具体用户 ID。 调用接口后,对应的 key 和 value 会缓存在本地,后续采集的事件,均包含缓存的 ID 信息。

适用平台:Andorid、iOS、H5、微信小程序 、支付宝小程序

参数 类型 说明 是否必选
loginIDKey String id 键名
loginId String id 值

resetAnonymousIdentity

方法说明:重置 ID-Mapping 3.0 匿名 id,只有在未登录情况下可以使用。

适用平台:Andorid、iOS、H5、微信小程序

参数 类型 说明 是否必选
identity String 新的匿名 Id 值

getIdentities

方法说明:获取 ID-Mapping 3.0 功能下已绑定的业务 ID 列表。

适用平台:Andorid、iOS、H5、微信小程序

bindOpenid

方法说明:多用户 ID 关联微信用户 Openid 时调用,参数为对应的关联用户 Openid。(v1.18.3 版本以上支持)。 调用接口后,对应的 key 和 value 会缓存在本地,后续采集的事件,均包含缓存的 ID 信息。 微信小程序 SDK 提供了 bindOpenid 接口将匿名 ID 设置为 OpenID。

⚠️此接口只有满足下面两个条件才能支持!不满足下面条件的可以使用 identify('openid', true) 接口; bindOpenid 仅在 ID-Mapping 3.0 支持,使用前请确认 SA 后端是否支持 ID-Mapping 3.0; bindOpenid 微信小程序 SDK 需要在 v1.18.3 版本上才支持!

适用平台:微信小程序

参数 类型 说明 是否必选
openid String openid 值

unbindOpenid

方法说明:多用户 ID 取消关联微信用户 Openid 时调用,参数为对应的关联用户 Openid。( v1.18.3 版本以上支持)。 调用接口后,会发送相关的解绑事件,同时会将本地缓存的 ID 信息中,对应的 key-value 清除(若存在)。

适用平台:微信小程序

参数 类型 说明 是否必选
openid String openid 值

bindUnionid

方法说明:多用户 ID 关联微信用户 Unionid 时调用,参数为对应的关联用户 Unionid。(v1.18.3 版本以上支持。 调用接口后,对应的 key 和 value 会缓存在本地,后续采集的事件,均包含缓存的 ID 信息。

适用平台:微信小程序

参数 类型 说明 是否必选
unionid String unionid 值

unbindUnionid

方法说明:多用户 ID 取消关联微信用户 Unionid 时调用,参数为对应的关联用户 Unionid。(v1.18.3 版本以上支持)。 调用接口后,会发送相关的解绑事件,同时会将本地缓存的 ID 信息中,对应的 key-value 清除(若存在)。

适用平台:微信小程序

参数 类型 说明 是否必选
unionid String unionid 值

trackAppInstall

方法说明:记录 $AppInstall 事件,用于在 App 首次启动时追踪渠道来源,并设置追踪渠道事件的属性

适用平台:Andorid、iOS

参数 类型 说明 是否必选
para Object 激活事件自定义属性

appFlush

方法说明:将所有本地缓存的日志发送到 SA

适用平台:Andorid、iOS

register

方法说明:注册所有事件都有的公共属性

适用平台:Andorid、iOS、H5、小程序

参数 类型 说明 是否必选
para Object 全局公共属性

代码示例:

 sensors.register({key1:"value1",key2 : "value2",}); 

注意: H5 的在页面生命周期内 小程序是在 App 生命周期内 App 是永久的

unRegister

方法说明:删除某些事件公共属性

适用平台:Andorid、iOS

参数 类型 说明 是否必选
name string 需删除的属性名称

代码示例:

 sensors.unRegister("key1"); 

clearRegister

方法说明:删除所有事件公共属性

适用平台:Andorid、iOS

setProfile

方法说明:设置用户属性

适用平台:Andorid、iOS、H5、小程序

参数 类型 说明 是否必选
para Object 用户属性

代码示例:

 sensors.setProfile({key1:"value1",key2:"value2"}); 

setOnceProfile

方法说明:首次设置用户属性,如果之前存在,则忽略,否则,新创建

适用平台:Andorid、iOS、H5、小程序

参数 类型 说明 是否必选
para Object 用户属性

代码示例:

 sensors.setOnceProfile({key1:"value1",key2:"value2"}); 

incrementProfile

方法说明:给一个或多个数值类型的 Profile 增加一个数值。只能对数值型属性进行操作,若该属性未设置,则添加属性并设置默认值为 0

适用平台:Andorid、iOS、H5、小程序

参数 类型 说明 是否必选
para Object[value:number] 增加数值属性

代码示例:

 sensors.incrementProfile({key1:2,key2:2}); 

appendProfile

方法说明:给一个列表类型的用户属性增加一个元素

适用平台:Andorid、iOS、H5、小程序

参数 类型 说明 是否必选
para Object{key:[value: array string]} 增加数值属性

代码示例:

 appendProfile({fruit:["苹果","西瓜"]}) 
 appendProfile({fruit:"西瓜"}) 
 appendProfile({fruit1:["苹果","西瓜"],fruit2:["葡萄]}) 

unsetProfile

方法说明:删除用户的一个用户属性

适用平台:Andorid、iOS、H5

参数 类型 说明 是否必选
name string 属性名称

deleteProfile

方法说明:删除用户所有用户属性

适用平台:Andorid、iOS、H5

popupClose

方法说明:设置弹窗按钮关闭回调 适用平台:Andorid、iOS、H5

参数 类型 说明 是否必选
plan_id string plan_id 计划ID
valueObj object cvalueObj 弹窗内容对象(在 sf 中配置的弹窗内容)

代码示例:

 注意 sensors 需要在 main.js 设置全局 
 /** 对弹窗点击事件,绑定事件处理函数 
   * @param {string} plan_id 计划ID 
   * @param {object} valueObj 弹窗内容对象(在 sf 中配置的弹窗内容) 
   */
    sensors.popupClose(function (plan_id, valueObj) { 
        console.log('plan_id: ', plan_id, ' valueObj: ', valueObj); 
    }); 

popupLoadSuccess

方法说明:设置弹窗加载成功回调 适用平台:Andorid、iOS、H5

代码示例:

 注意 sensors 需要在 main.js 设置全局 
 /** 
   * @param {string} plan_id 计划ID 
   * @param {object} valueObj 弹窗内容对象(在 sf 中配置的弹窗内容) 
   */ 
    sensors.popupLoadSuccess(function (data) {
        console.log('加载弹窗成功: ', data); 
    }); 

popLoadFailed

方法说明:设置弹窗加载失败回调 适用平台:Andorid、iOS、H5

参数 类型 说明 是否必选
valueObj object 弹窗内容对象(在 sf 中配置的弹窗内容)
code string code 错误码
message string 错误信息

代码示例:

 注意 sensors 需要在 main.js 设置全局 
 /** 
   * @param {object} valueObj 弹窗内容对象(在 sf 中配置的弹窗内容) 
   * @param {string} code 错误码 
   * @param {message} 错误信息 
   */ 
    sensors.popLoadFailed(function (valueObj,code,message) { 
        console.log('失败回调: '); 
    }); 

popupClick

方法说明:设置弹窗点击回调 适用平台:Andorid、iOS、H5

参数 类型 说明 是否必选
valueObj object 弹窗内容对象(在 sf 中配置的弹窗内容)

代码示例:

 注意 sensors 需要在 main.js 设置全局
/**
 * @param {object} valueObj 弹窗内容对象(在 sf 中配置的弹窗内容)
 */  
sensors.popupClick(function (valueObj) {
    console.log('click:',valueObj);
});

注意:以上方法,可以直接调用,不支持的端调用后无效,控制台会打印日志。

隐私、权限声明

1. 本插件需要申请的系统权限列表:

2. 本插件采集的数据、发送的服务器地址、以及数据用途说明:

插件使用的神策分析 SDK 会采集数据,详情可参考:https://manual.sensorsdata.cn/sa/latest/tech_sdk_client-1573786.html

3. 本插件是否包含广告,如包含需详细说明广告表达方式、展示频率:

许可协议

Apache License Version 2.0, January 2004 http://www.apache.org/licenses/

TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION

  1. Definitions.

    "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.

    "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.

    "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.

    "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.

    "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.

    "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.

    "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).

    "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.

    "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."

    "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.

  2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.

  3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.

  4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:

    (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and

    (b) You must cause any modified files to carry prominent notices stating that You changed the files; and

    (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and

    (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License.

    You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.

  5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.

  6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.

  7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.

  8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.

  9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.

    END OF TERMS AND CONDITIONS

    APPENDIX: How to apply the Apache License to your work.

    To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives.

    Copyright 2015-2021 Sensors Data Inc.

    Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

使用中有什么不明白的地方,就向插件作者提问吧~ 我要提问