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

Set i18n_redirect cookie path to '/' #143

Merged
merged 2 commits into from Jan 14, 2019
Merged

Set i18n_redirect cookie path to '/' #143

merged 2 commits into from Jan 14, 2019

Conversation

ghost
Copy link

@ghost ghost commented Oct 17, 2018

Set i18n_redirect cookie path to '/'.

Without that the cookie is created for every page...

Set i18n_redirect cookie path to '/'.

Without that the cookie is created for every page...
@paulgv
Copy link
Collaborator

paulgv commented Oct 22, 2018

Hi @MisterEffix, thanks for the PR!
I wonder why we should avoid setting the cookie on all pages, is it an issue?
In theory, we would like to be able to redirect to the browser's language from any page right? Maybe we should have a way of customizing the cookie options from Nuxt's config instead, what do you think? The defaults could be let as is and you would be able to set the cookie's path and duration from the config.

@appinteractive
Copy link

I think this is needed as you do not want to be sammed by cookies for every route you set the locale. You want to set the locale site-wide and not only for the current route.

grafik

@ghost
Copy link
Author

ghost commented Dec 7, 2018

@appinteractive explained exactly what I meant.
Sorry, I should have taken the time to do it myself.

Thanks @appinteractive

@paulgv paulgv merged commit 9ad540e into nuxt-modules:master Jan 14, 2019
@paulgv
Copy link
Collaborator

paulgv commented Jan 14, 2019

Thanks @MisterEffix ! Sorry for the delay.

farnabaz pushed a commit to farnabaz/i18n-module that referenced this pull request Mar 25, 2021
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