char/avril
(wip) why'd you have to go and make things so complicaaaaated?
git clone https://git.t4t.associates/char/avril
5553f00
main
1declare module"ext:core/ops" { 2export type PatternComponent = 3| "protocol" 4| "username" 5| "password" 6| "hostname" 7| "port" 8| "pathname" 9| "search" 10| "hash" ; 11export type PatternInit = Partial < Record < PatternComponent | "baseURL" , string >>; 12export type PatternInput = string | PatternInit ; 13export type NativeComponent = [ pattern :string , regexp :string , names :string [], flags :string ]; 14 15export function op_urlpattern_parse ( 16args :[ input :PatternInput , base :string | null , ignoreCase :boolean ], 17) :[ pattern :[ components :NativeComponent [], hasRegExpGroups :boolean ], error :null ] | [ pattern :null , error :string ]; 18export function op_urlpattern_match_input ( 19args :[ input :PatternInput , base :string | null ], 20) :[ values :Record < PatternComponent , string > | null , error :null ] | [ values :null , error :string ]; 21}