Jan
banner
amann.work
Jan
@amann.work
Maintainer of 🌐 https://next-intl.dev · Guest lecturer for React Web Applications at FHV · Partner for User Interface Engineering

@jamannnnnn on X
If you already gave it a shot, please share your feedback here:

github.com/amannn/next-...
Message extraction feedback · amannn next-intl · Discussion #2036
Please use this thread to share feedback related to useExtracted. This is my public TODO list for the feature: #2087 (but please keep the feedback here)
github.com
November 27, 2025 at 2:45 PM
Reposted by Jan
Before:
- Think of a message ID (This is often hard!)
- Define your message text
- reference the message ID

After:
- Tag your string as translatable
November 26, 2025 at 7:37 PM
Btw. I saw your GitHub issue, will reply a bit later on today!
November 27, 2025 at 9:48 AM
Nice! How did you set up the migration? Are you using different folders for useExtracted and useTranslations messages?

There's btw. another release scheduled for this week with a few fixes for useExtracted: github.com/amannn/next-... — just as a heads-up!
November 27, 2025 at 9:47 AM
Ok nice! Hope it stays like that, bundling behavior of Next.js can be peculiar…
November 25, 2025 at 4:26 PM
But you'd still load your server implementation like getItemServer on the client side, right? If it's doable for you, it might be worth considering if another API requires less magic …
November 25, 2025 at 2:16 PM
So it's kind of a factory function that returns functions for both the server and client? You could check with the new bundle analyzer (next experimental-analyze --serve) on the latest canary if everything tree-shakes as expected.
November 25, 2025 at 2:16 PM
Ah yep, got it! Hmm, to be honest—not entirely sure. It kind of rings a bell this pattern, I think I saw it in some userland code in a GitHub issue. next-intl doesn't do it though and I don't really have first-hand experience with it.
November 25, 2025 at 2:16 PM
Hey! Hmm, good question. Why did you move it to a dynamic import in the first place?
November 25, 2025 at 11:35 AM
It’s just really helpful to focus on a single framework until we get there. And from there, eventually I‘d like to take all the learnings and make them available to other React frameworks. It will take time.
November 15, 2025 at 7:59 AM
I mean the bigger topic is that it would be pretty cool if next-intl would have first-class support for other frameworks. I think eventually we’ll get there, but it’s pretty far down the road. I hope that next year, next-intl will somewhat reach „feature completion“, at least more or less.
November 15, 2025 at 7:59 AM
If that’s an option for you, that might work. But: Things are still changing, if you can wait a bit, maybe this will be easier soon. I‘m currently working with Donny, the creator of SWC, to move all the AST modification to an SWC plugin. I guess using that somehow in a Vite app should be possible.
November 15, 2025 at 7:56 AM
What will be missing for you is the part where inline messages are swapped out for keys. So useExtracted in theory already works in Vite, but it will always use the message you've defined inline (typically your source locale).
November 14, 2025 at 3:15 PM
But it's something further down the road, I'd like to get more confidence that this works well for Next.js first.
November 14, 2025 at 2:59 PM
For now, useExtracted is Next.js-only. But the Next.js-specific integration point is a Turbopack loader which is literally just this small file here: github.com/amannn/next-.... So the feature was certainly implemented to be useful for other bundlers like Vite as well.
November 14, 2025 at 2:59 PM
Got it! Let me know if it works well for you when you get a chance to try it!
November 12, 2025 at 9:53 PM
Did you have a chance to try it yet? :)
November 12, 2025 at 9:12 PM