Skip to content

Latest commit

 

History

History
12 lines (8 loc) · 1.41 KB

File metadata and controls

12 lines (8 loc) · 1.41 KB

Parse URL Params medium #infer #string #template-literal

by Anderson. J @andersonjoseph

Take the Challenge

You're required to implement a type-level parser to parse URL params string into an Union.

ParseUrlParams<':id'> // id
ParseUrlParams<'posts/:id'> // id
ParseUrlParams<'posts/:id/:user'> // id | user

Back Share your Solutions Check out Solutions