Define route priority


For blogging purpose, I have a category page with that url :

// :fullslug is the slug hierarchy of mly categories

I want to keep that category hierarchy in my post detail url logic, like that :

// :fullslug is the slug hierarchy of my categories, and :slug the slug of my post

My problem is that, if I go to the url of my post detail, the category page is still used. I can understand why, because I have a wildstar in my url logic, but I don’t see how I can bypass the problem. I need a way to define priorities to pages.

Any help would be appreciated

Hey @Zmove

These two routes do indeed conflict and even with priority it is impossible to match the secondary route.

The best thing to do would be to make the route that has the secondary route more specific or include a static segment, this is the same as a priority definition.


I came to to same conclusion so I prefixed my route.

However, while I was thinking to my problematic, I thought it would be a nice addition to be able to limite the size of the path when using wildcard.

I was not in that case, but if you are in a case where your :fullslug always have the same size (ex : path1/path2), it could be nice to be able to do something like this in you path pattern :


Like that, you can have more control when you use the wildcard