- From: Domenic Denicola <notifications@github.com>
- Date: Mon, 15 Dec 2014 11:15:21 -0800
- To: slightlyoff/ServiceWorker <ServiceWorker@noreply.github.com>
Received on Monday, 15 December 2014 19:15:50 UTC
> If getAll returns different types, given that workers are still pretty rare, I'm worried that code would appear to work, go live, then start failing because a worker was present. Good point. Very interesting. Is there a scenario when getAll() is useful without filtering by type? Your examples seem like they would benefit from a filter on window. Perhaps `clients.getWindows()` + `clients.getAll()` would be helpful for avoiding this? > Assuming we went with the above, what API would you prefer for opening a window, considering a constructor here is undesirable? clients.openWindow(url), WindowClient.open(url)? If I'm understanding correctly, any new window clients will be added to the collection of all clients, right? If so, then I think the former seems a bit nicer, since `clients.openWindow` modifying the return value of `clients.getAll` makes more sense than `WindowClient.open` doing so. --- Reply to this email directly or view it on GitHub: https://github.com/slightlyoff/ServiceWorker/issues/588#issuecomment-67048076
Received on Monday, 15 December 2014 19:15:50 UTC