1.0.0-beta5 • Published 4 years ago

@liuyunjs/timer v1.0.0-beta5

Weekly downloads
1
License
MIT
Repository
github
Last release
4 years ago

install


@npm: npm install @liuyunjs/timer -S

@yarn: yarn add @liuyunjs/timer

Quick


import {timeout, interval} from '@liuyunjs/timer';

const timer = timeout();
const timer2 = interval();

timer.set(() => console.log('hello world'), 1000);
timer.clear();

timer2.set(() => console.log('hello world'), 1000);
timer2.clear();