WICG / idle-detection

A proposal for an idle detection and notification API for the web
Other
68 stars 22 forks source link

Remove IdleState interface #18

Closed reillyeon closed 4 years ago

reillyeon commented 4 years ago

The IdleState interface does not seem necessary. Two alternatives:

  1. Make IdleState a dictionary.
  2. Add the fields of IdleState directly to IdleDetector.

The disadvantage of (1) is that interface members should not be dictionaries and so a new getState() method should be added. This adds additional overhead. I prefer option (2).