DEV Community

MokDevelopment
MokDevelopment

Posted on

i18Next's default locale and next build command

Hi there.

As i18Next has no native way to force the locale as a folder prefix we all use this "default" hack. By doing so "default" is redirected via middleware to "en" (if thats your default lang) to ensure the folder structure stays the same for all the languages.

Fair enough - feels a little bit hacky and not native - but why not - it does its job.

My problem is now that next build tries to create pages for "default" as well. How do I suppress this error creating step?

Image description

Thanks

Top comments (0)