-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Labels
feature / enhancementNew feature or requestNew feature or request
Description
Describe the problem
The current SvelteKit Reroute functionality doesn't support dynamic rerouting for localization where settings are stored in a database. We need to implement a multi-domain, multi-prefix localization system that allows flexible domain/language combinations.
Example configuration:
- Domains: example.com, example.uk, example.gr, example.fr
- Localizations: en-gb, el-gr, en-gr, fr-fr, en-fr
Domain/prefix mappings:
el-gr:
- example.com/el-gr/
- example.gr/
en-gr:
- example.com/en-gr/
- example.gr/en/
en-gb:
- example.com/
- example.uk/
Describe the proposed solution
Modify the Reroute function to return MaybePromise<void | string>
and update its implementation in server/response.js
and client/client.js
.
A proof-of-concept implementation: nikosgram@70d808e
I would appreciate feedback on this approach to ensure I'm not overlooking any potential issues or better alternatives.
Alternatives considered
No response
Importance
i cannot use SvelteKit without it
Additional Information
No response
IvanMatev
Metadata
Metadata
Assignees
Labels
feature / enhancementNew feature or requestNew feature or request