next-intl icon indicating copy to clipboard operation
next-intl copied to clipboard

404 Not Found: "No intl context found. Have you configured the provider?"

Open ChiefORZ opened this issue 1 year ago • 3 comments

Description

next-intl@beta breaks with next@^13.4.10 and even canary - when using next-intl/link in your project. i think this bug is introduced by next itself, i created an issue on their side https://github.com/vercel/next.js/issues/53147 and just wanted to create a reference here if anybody stumbles upon it

Mandatory reproduction URL (CodeSandbox or GitHub repository)

https://codesandbox.io/p/sandbox/elegant-joji-mxx7fn

Reproduction description

Steps to reproduce:

  1. Open reproduction url
  2. See error: No intl context found. Have you configured the provider?

Expected behaviour

Next.js has to fix it

ChiefORZ avatar Jul 25 '23 06:07 ChiefORZ

Thank you so much for analyzing the bug and creating a good reproduction! Hopefully this gets fixed soon on the Next.js side! 🙏

amannn avatar Jul 25 '23 08:07 amannn

I'm new to next-intl, but I don't see where the use of next-intl/link is documented? I thought we had to create our own with createLocalizedPathnamesNavigation and createSharedPathnamesNavigation from the next-intl/navigation package.

maxijonson avatar Apr 09 '24 17:04 maxijonson

I thought we had to create our own with createLocalizedPathnamesNavigation and createSharedPathnamesNavigation from the next-intl/navigation package.

Yep, that's the case. The reproduction above uses an older pre-release beta version of next-intl which had a next-intl/link at the time—this API is no longer available.

amannn avatar Apr 11 '24 16:04 amannn

Seems like this was resolved upstream.

amannn avatar Jun 05 '24 09:06 amannn