Reputation: 59
After implementing localization in our Angular (v15) project and configuring i18n, the base URL now includes a language code. As a result, when our users attempt to open the application URL suggested by Google Chrome, it leads to a 404 error because they are using our old URL("https://app.something/dashboard").inorder to prevent this i want the english version url to be same like old url.
i want to configure the url as below
For the default locale (English):
https://app.something/dashboard
For other languages (e.g., Arabic, French), you want to prefix the language code to the URL:
https://app.something/{language_code}/dashboard
I tried adding an index.html
file to the dist
folder to redirect to the correct language code, but it sometimes fails
Upvotes: 1
Views: 144