Giter VIP home page Giter VIP logo

Comments (7)

titouv avatar titouv commented on September 4, 2024 1

Thanks for resolving, the issue. I experimented with server context on my side also, but setting headers is a better solutions. Thanks 👍

from next-international.

QuiiBz avatar QuiiBz commented on September 4, 2024

Hey, what's the error you're getting?

from next-international.

titouv avatar titouv commented on September 4, 2024

Sorry, i get the following Error: No locale set, make sure to use the I18nProviderServer component

https://github.com/titouv/next-international-repro-bug

Here is the link to the repro, the root path is failing with the previous errors but the root with async wrapper and the root with the non async wrapper works perfectly. Maybe there is something I don't understand about NextJS behavior

from next-international.

titouv avatar titouv commented on September 4, 2024

With further testing it appears the error also appears when navigating to a page, a simple reload removes the issue but the navigation make this error happen even though its wrapped

from next-international.

titouv avatar titouv commented on September 4, 2024

Seems in the repro and in the example from the repo (at least on my side), the getLocale function is run before the setLocale, which is thus problematic. If this can give an hint

from next-international.

QuiiBz avatar QuiiBz commented on September 4, 2024

Looks like cache isn't the ideal solution to save the current locale for a given session. I'll try to use server contexts instead.

from next-international.

QuiiBz avatar QuiiBz commented on September 4, 2024

I've published 0.5.2 which resolves the issue on my side. Could you try again and open another issue if needed? Thanks.

from next-international.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.