News for hackers. Stuff that matters.
Re:Next.js Layouts RFC: Nested routes and layouts, designed ... by kilburn on Tuesday May 24, 2022 @01:29AM (#31488338)
It makes route localization a second-class citizen in the framework at best, or a totally unsupported hack-your-own-solution thing at worst.
Re:Next.js Layouts RFC: Nested routes and layouts, designed ... by aj0strow on Thursday May 26, 2022 @03:50AM (#31515800)
It seems like a path prefix like "/en/books" or "/es/books" could be supported with a base url config.

Localized path segments like "/books" or "/libros" could be supported with a path segment mapping configuration.

It should work fine in theory. I guess those configs don't exist yet. Or is there something else that route localization requires?

Re:Next.js Layouts RFC: Nested routes and layouts, designed ... by julianbuse on Tuesday May 24, 2022 @04:44AM (#31489563)
if it helps, you could use middleware in next.js to handle routing to separate folders easier.
Re:Next.js Layouts RFC: Nested routes and layouts, designed ... by kilburn on Tuesday May 24, 2022 @04:47PM (#31497382)
Middleware won't work if you use "next export" to get a truly static site though, which is by far my preferred mode of operation whenever possible.

This is what I meant when I said "second-class citizen at best".

Re:Next.js Layouts RFC: Nested routes and layouts, designed ... by julianbuse on Friday May 27, 2022 @04:21AM (#31527260)
ah I see. Maybe try the route rewriting in next.conf.js? I think thats what the file is. That might work for static sites.