v.0 by Sergey Chernov
2019-01-13 15:01

U8 timers

In short:

  • await sleep(millis);
  • timeout(millis, callback);
  • setTimeout/clearTimeout legacy functions.

Also you can

import { now, currentMillis } from 'timers' and get:

  • now() - current unix time but in milliseconds
  • currentMillis() milliseconds passed since some point of JS library initialization.