Re: [sensors] Dependency on [DOM] due to inheriting from EventTarget

> Note that there are no DOM dependenices in the example as far as I 
can tell.

Don't get hung up on this. The **only** reason that EventTarget is 
being used is because it's the closest thing to EventEmitter. If that 
existed, we wouldn't have this problem, because:

```js
var location = new Sensor.GPS();

location.once("change", function() {
  // Located. 
  console.log(location.latitude, location.longitude);
});
```



-- 
GitHub Notif of comment by rwaldron
See https://github.com/w3c/sensors/issues/21#issuecomment-111274650

Received on Thursday, 11 June 2015 20:52:52 UTC