RouteMatcher Module
Functions and values
Function or value | Description |
Full Usage:
RouteMatcher.matchStrings template url
Parameters:
string
-
The template to match the URL against
url : string
-
The URL to match
Returns: Validation<(UrlTemplate * UrlInfo * UrlMatch), StringMatchError>
A validation that contains the UrlTemplate obtained from the provided string, the matched URL, and the match result if the URL matches the template
or a list of StringMatchErrors if there were problems parsing the template, the URL or if the URL doesn't match the template.
|
|
Full Usage:
RouteMatcher.matchTemplate template url
Parameters:
UrlTemplate
-
The template to match the URL against
url : UrlInfo
-
The URL to match
Returns: Validation<UrlMatch, MatchingError>
A validation that contains the matched URL and the match result if the URL matches the template
or a list of MatchingErrors if the URL doesn't match the template.
|
|
Full Usage:
RouteMatcher.matchUrl template url
Parameters:
UrlTemplate
-
The template to match the URL against
url : string
-
The URL to match
Returns: Validation<(UrlInfo * UrlMatch), StringMatchError>
A validation that contains the matched URL and the match result if the URL matches the template
or a list of MatchingErrors if the URL doesn't match the template.
|
|