I have one issue with express I want to use "^"
as we use it in Javascript regex but unfortunately it does not work…
so here i added “^” to give pattern to the storeName path parameter::
router.get(
"/stores/:storeName(^[a-zA-Z0-9_-][a-zA-Z0-9_-]{0,})",
async(req, res) => {
console.log("here");
}
);
This route is not mach this route
"http://localhost:3000/stores/saidm"
nor this
"http://localhost:3000/stores/^saidm"
I expected the route to be matched for at least one of this paths