@yeepay/browser-support-detector
v0.1.3
Published
browser support detector sdk.
Downloads
18
Keywords
Readme
易宝支付,浏览器兼容性检测 sdk,Trident 内核
How it work?
在入口 html 处引入 sdk cdn :
<script type="text/javascript" src="//img.yeepay.com/federation/npm/yeepay/browser-support-detector/<VERSIION>/index.min.js"></script>示例:
index.hmtl
<html>
<head>
/* ... */
</head>
<body>
/*...*/
<script type="text/javascript" src="//img.yeepay.com/federation/npm/yeepay/browser-support-detector/<VERSIION>/index.min.js"></script>
</body>
</html>❗️必须在 body 标签内部或之后, 并且其他 script 标签之前注入。
For Developer
安装依赖
npm install一、开发 unsupport 页面
- 将 src/unsupport.html 首部 head 注释解除,将 css 注入。
- 启动
npm run start二、编译
页面开发完成后,先编译:
- 将 src/unsupport.html 首部 head 注释。
- 编译
npm run compile三、测试
编译后方可测试:
npm run test四、构建
编译后方可构建:
npm run build五、发布 npm
npm publish上传至 img.yeepay.com/federation/npm/yeepay/browser-support-detector 目录下,版本号为 package.json 中的 version 字段。
