Replies: 2 comments 5 replies
-
That specific section in the explainer is talking about ordering specifically for the service worker API. It has its own rules of how things must be ordered. We are also planning to have a URLPatternList object that would be an ordered list of URLPattern objects. The ordering would be determined by how you create the list, though. We weren't planning on automatic ordering based on rules like SW scopes for URLPatternList. Does URLPatternList solve your use case? Or is it more you need the automatic order determination like service worker scopes uses that you need? |
Beta Was this translation helpful? Give feedback.
-
This is now being discussed in issue #61. |
Beta Was this translation helpful? Give feedback.
-
Hello,
Reading https://github.com/WICG/urlpattern/blob/master/explainer.md#scope-match-ordering it makes me understand there is a way for different instances of
URLPattern
s to be ordered or that there is a different entity that is able to, given a list of instances ofURLPattern
s and a url string/users/20
, match the most specificURLPattern
.Is this what that part means?
I'm asking because this would be necessary for JS dynamic client side routing which seems to be one of the use cases and could potentially enable client side routers to take advantage of the API
Beta Was this translation helpful? Give feedback.
All reactions