useless-progress
Produce a useless automatic scrolling bar that grows on its own.
Download
npm i useless-progress
example
import Progress from 'useless-progress';
const progress = new Progress({
onprogress: function (progress) {
console.log(progress)
}
})
progress.start()
config
onprogress | Callback when progress increases,parameter is the current progress | function | - |
extremeTime | Time from 0 to 0.99 (ms) | number | 60000 |
frequency | Frequency of progress increase | number | 200 |
method
start() | |
end() | Stop working and set progress to 1 |
getProgress() | |
setProgress() | |