qProgress.js是一个简单的网页顶部加载进度条JavaScript插件,可以创建漂亮的,彩色的可视化加载进度条状态。初始化加载进度条// ES const qprogress = new QProgress() // UMD window.qprogress = new qProgress();开始加载qprogress.start();结束进度qprogress.finish()设置百分比进度// 50% qprogress.set(0.5) // 100% qprogress.set(1.0)设置增加百分比qprogress.inc(0.2)自定义参数 // minimum percentage minimum: 0.12, // height in px height: 2, // background color color: '#1890ff', // is colorful? colorful: true, // easing function easing: 'ease', // animation speed speed: 400, // automatic increment trickle: true, trickleSpeed: 400, // parent container parentNode: 'body', // default selectors barSelector: '[role="bar"]', pegSelector: '[role="peg"]',
preview Points Download 6毛Download Share Download
未经允许不得转载: ICode联盟 » Plugin Special Effects » 网页顶部加载进度条插件qProgress.js