Re: [w3c/ServiceWorker] Scope matching algorithm breaks sites that don't end in a slash (#1272)

> I think this might be correct. Scopes were never a universally popular thing.

That may be true, and perhaps the best thing would have been to always scope to the origin and force apps to design around that. But scopes are a thing, so they should work.

Having said that, I do think scope was a valuable feature. While it's easy to say to developers, "oh you should just use "maps.google.com" instead of "google.com/maps", the reality is that you'd be telling a gigantic organisation like Google Maps that they have to change all of their URLs before they can begin using your technology. That's going to drastically lower the the cost/benefit ratio for implementing Service Workers (and Web App Manifests). So I'd rather we fix scope, than simply tell developers, "best to design your site such that scope is `/`".

> Interestingly, it looks like this was considered in issue 3: #3.

Interesting. That issue was closed with "Per today's f2f discussion, this is your app's responsibility."

It looks like that decision was made back in the day when "*" was still part of the syntax. Still, I don't even see then how the app could've taken responsibility for this. There is no way (with or without the * wildcard syntax) to ensure that "/foo" and "/foo/*" are in-scope, but "/foobar" is not.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/issues/1272#issuecomment-364280626

Received on Thursday, 8 February 2018 23:12:00 UTC