Hello,
I do really like Fresh!
However, I am missing some control on the routing.
For instance, I would like to make a framework for localized routing (for instance: /mon-nom/maurice (FR -> french page) and /my-name/maurice (EN -> english page).
To make such a system possible, I need to be able to rewrite a request before it passes through the file based routing. Then I could for instance set the language on the ctx.state object and rewrite the URL/route to the folder structure (which will be English always).
This way, localization is easier. This is also how frameworks like Paraglide are working with localized routes.
Is this possible, if not, could it be made possible?
Would be great!
Hello,
I do really like Fresh!
However, I am missing some control on the routing.
For instance, I would like to make a framework for localized routing (for instance: /mon-nom/maurice (FR -> french page) and /my-name/maurice (EN -> english page).
To make such a system possible, I need to be able to rewrite a request before it passes through the file based routing. Then I could for instance set the language on the ctx.state object and rewrite the URL/route to the folder structure (which will be English always).
This way, localization is easier. This is also how frameworks like Paraglide are working with localized routes.
Is this possible, if not, could it be made possible?
Would be great!