URLPattern
open class URLPattern(input: String, baseURL: String, options: URLPatternOptions = definedExternally)(source)
The URLPattern interface of the URL Pattern API matches URLs or parts of URLs against a pattern. The pattern can contain capturing groups that extract parts of the matched URL.
Properties
Functions
Link copied to clipboard
open external fun exec(input: String = definedExternally, baseURL: String = definedExternally): URLPatternResult?
open external fun exec(input: URLPatternInit, baseURL: String = definedExternally): URLPatternResult?
The exec() method of the URLPattern interface takes a URL or object of URL parts, and returns either an object containing the results of matching the URL to the pattern, or null if the URL does not match the pattern.