← Back to release summary

URLPattern: Inherit left, wildcard right

Category
Miscellaneous
Type
No developer-visible change
Status
Enabled by default (Chrome 121)
Intent stage
None

Summary

Behavior changes to patterns which are constructed using a base URL, the constructor string syntax, or both -- but not any pattern which explicitly specifies components separately without a base URL. * Components are not inherited from a base URL if an "earlier" component is explicitly specified. * In the string format, unspecified "later" components are implicitly wildcarded, rather than required to be empty (with the exception of the port, which is always taken to be specified when the hostname is). * Username and password are never implicitly specified or inherited. This makes patterns more expansive than before, in cases where wildcards are likely to be desirable. See https://github.com/whatwg/urlpattern/pull/198.

Standards & signals

View on chromestatus.com