Re: [ServiceWorker] Unable to easily distinguish top-level navigations (#673)

Yeah, that's what I was thinking, it would be a shortcut like `response.ok`.

@slightlyoff is that what you're thinking? As in:

```js
Object.defineProperty(Request.prototype, 'canCreateClient', {
  get() {
    var clientCreatingContexts = [
      'embed', 'form', 'frame',
      'hyperlink', 'iframe', 'internal',
      'location', 'metarefresh', 'object',
      'serviceworker', 'sharedworker',
      'worker'
    ];
    return clientCreatingContexts.indexOf(this.context) != -1;
  }
});
```

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

Received on Monday, 13 April 2015 10:49:00 UTC