(Note, this PR depends on #13 which should be merged first.)
This PR adds canonicalization of pattern strings. This is done via the
path-to-regexp encode callback feature. These callbacks are invoked on
plain text parts of the pattern string. Values within regular
expressions, etc, are not passed to the encode callbacks. This PR
provides the appropriate encode callback for each component.
In addition, the check for an ASCII regular expression now must be
performed by path-to-regexp itself. This PR updates the modified
path-to-regexp to do this. This change is also available in:
(Note, this PR depends on #13 which should be merged first.)
This PR adds canonicalization of pattern strings. This is done via the path-to-regexp encode callback feature. These callbacks are invoked on plain text parts of the pattern string. Values within regular expressions, etc, are not passed to the encode callbacks. This PR provides the appropriate encode callback for each component.
In addition, the check for an ASCII regular expression now must be performed by path-to-regexp itself. This PR updates the modified path-to-regexp to do this. This change is also available in:
https://github.com/wanderview/path-to-regexp/tree/urlpattern-6-ascii-regexp