Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add redirect from '/en' to '/' #149

Merged
merged 1 commit into from
May 7, 2020
Merged

Add redirect from '/en' to '/' #149

merged 1 commit into from
May 7, 2020

Conversation

Faulik
Copy link
Contributor

@Faulik Faulik commented May 2, 2020

Based on this #147 discussion.
Some prettier style changes are applied on hasky, so kept them.

Copy link
Owner

@aralroca aralroca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm sorry if it took me a while to check this out. I've been busy these days.

Looks good to me. Maybe we can rename the redirectToDefaultLang to another name more understandable in future major releases. Right now it is ok.

@aralroca aralroca added this to the 0.16.0 milestone May 7, 2020
@aralroca aralroca merged commit f116c12 into aralroca:master May 7, 2020
@aralroca
Copy link
Owner

aralroca commented May 7, 2020

I'm going to pre-release this in 0.16.0-canary.1 if you want to try it in a real project. This will be released on 0.16.0 (probably today or tomorrow).

@tronjsdev
Copy link

tronjsdev commented May 14, 2020

Hi, correct me if I wrong, it seems that currently redirectToDefaultLang only works in "build step" right? I tried to use the flag in dynamic page routes but it doesn't seem to work.

@aralroca
Copy link
Owner

More or less @tronjsdev... redirectToDefaultLang it also works using a custom server. However if you are following this example:

It's not fully supported by next-translate yet. There is an open issue here #129 to evolve this.

@aralroca
Copy link
Owner

@all-contributors add @Faulik for code

@allcontributors
Copy link
Contributor

@aralroca

I've put up a pull request to add @Faulik! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants