[ServiceWorker] Service Worker constructor instead of navigator.serviceWorker (#660)

Why doesn't Service Worker use Constructor instead of the current approach? Is this a matter of taste?

```
var sw = new ServiceWorker('/path/to/sw.js',{scope : '/'});
sw.onregister = function(evt){
      console.log('Service Worker is successfully registered');
};
sw.onerror = function(er){
     console.log(er.message);
};


---
Reply to this email directly or view it on GitHub:
https://github.com/slightlyoff/ServiceWorker/issues/660

Received on Tuesday, 24 March 2015 06:56:05 UTC