潮点视频前端工具库
build by cdFe teamwork, goal to reduce some front-end work. hope you enjoy. please remember es6+ runtimes is required 潮点视频前端开发,目标是降低一些业务常用的功能的重复开发 以及多处复用。需要es6及以上环境
关键文件目录
dist/
├── cd-fe.js (UMD, default)
├── cd-fe.min.js (UMD, compressed)
├── cd-fe.esm.js (ECMAScript Module)
├── cd-fe.esm.min.js (ECMAScript Module, compressed)
└── cd-fe.d.ts (TypeScript Declaration File)
开始使用
安装方式
npm install cd-fe
In browser:
<script src="/path/to/cd-fe.min.js"></script>
使用方法 待完善
cdFe.appenJs(script1, script2, ..., scriptN)
.then(() => {})
.catch((err) => {})
.finally(() => {});
cdFe.appenCss(link1, link2, ..., linkN)
.then(() => {})
.catch((err) => {})
.finally(() => {});
cdFe.ColorMode
/*
addClass: ƒ h(e)
getColorScheme: ƒ w()
preference: "system"
removeClass: ƒ (e)
value: 'light'
*/
scrollSpy的使用请参考 scrollSpy readMe
浏览器兼容
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Opera (latest)
- Edge (latest)
- Internet Explorer ie9+
代码使用了 Promise / Arrow Function ,请确保您的环境兼容