hozana / next-translate-routes

Flexible and translated routes for Next.js without custom server
MIT License
115 stars 30 forks source link

Is there a way to translate dynamic pages? #16

Open JonasGreim opened 2 years ago

JonasGreim commented 2 years ago

image image

Hey, is there a way how to translate specific named dynamic pages (like in the picture above with "hello")? The documentation/readme only explains how to restrict dynamic pages and how to append pre- and suffixes.

Thanks

cvolant commented 2 years ago

That is indeed not supported, yet. But it might be possible... It might be good, it might not be... :thinking: One must think about it twice before implementing that behavior.

ozcancelik commented 2 years ago

Hey,

Usually I use folder structure like this.

pages/page-name/index.js 
pages/page-name/[slug].js

I think it would be great if there could be such an improvement. Could be "nice to have" improvement.

IvoHohl commented 2 years ago

Any news on that? Got some problems with dynamic pages. When I use next-translate link for dynamic pages the "parameter" is removed in the link. I think this has something to do with the missing feature but maybe its also another "problem".

E.g.

  1. I'm rendering some static Path pages like that image
  2. I'm routing to the pages like that: image
  3. This is what I get rendered: image

I think this is because some routes are checked when generating static pages. As soon I use the Next/Link instead of link from next-translate-routes everything works like I would expect it.

sdk1990 commented 1 year ago

+1!

cvolant commented 1 year ago

@IvoHohl do you still have the issue with the last version of next-translate-routes?

@sdk1990 +1 on the feature request or on IvoHohl's issue?

robatronPrime commented 9 months ago

Hey, I'm having the same issue. Was a solution made?