Fix dynamic default locale routing
This commit is contained in:
+6
-2
@@ -28,8 +28,12 @@ export function stripLocalePrefix(pathname: string): string {
|
||||
return pathname || "/";
|
||||
}
|
||||
|
||||
export function getLocalizedPath(locale: string, pathname = "/"): string {
|
||||
return getLocalizedPathWithDefault(locale, pathname, routing.defaultLocale);
|
||||
export function getLocalizedPath(
|
||||
locale: string,
|
||||
pathname = "/",
|
||||
defaultLocale: AppLocale = routing.defaultLocale,
|
||||
): string {
|
||||
return getLocalizedPathWithDefault(locale, pathname, defaultLocale);
|
||||
}
|
||||
|
||||
export function getLocalizedPathWithDefault(
|
||||
|
||||
Reference in New Issue
Block a user