video-freqtimeupdate

1.0.3 • Public • Published

The fork

Video Frequent Time Update

HTML5 videos have some quality events. One of those is timeupdate: dispatched when the time indicated by the element's currentTime attribute has changed.

Unfortunately, this event frequency varies between 4Hz and 66Hz(!), so it's not very useful for building interfaces that need to be up to date with the video time.

Enter Frequent Time Update. With 100ms intervals, freqtimeupdate events are sent out continously while the video plays.

Usage

  1. npm i -S video-freqtimeupdate
  2. import * as frequent from 'video-freqtimeupdate'

To add a listener

frequent.add(videoEle, cb);

To remove the listener

frequent.add(videoEle, cb);

Readme

Keywords

none

Package Sidebar

Install

npm i video-freqtimeupdate

Weekly Downloads

2

Version

1.0.3

License

none

Unpacked Size

2.98 kB

Total Files

3

Last publish

Collaborators

  • saadshahd