A module to do routing inside your components. Meant to be used with @erickmerchant/framework. Does not do anything with the history API for you.
/* component.js */const route link =const component = html``
A route can contain multiple segments separated by slashes. Segments can begin with a colon. Those are replaced by props from the object in the case of
link or populate params in the case of
on. Colon prefixed segments can have a *, +, or ? modifier at the end, which change whether it is required and whether it consumes multiple segments.
widlcard.mjs provides a more minimal variation.
/* component.js */const component = html``