Is it possible to use Intlayer with Next.js without [locale] in the page path?
Yes, it is possible to use Intlayer with Next.js without [locale] in the page path. However, it is not recommended to do so, because splitting your page allows you to trigger more keywords on search engines. Your SSR may also be impacted.
If you want to do so, follow the same steps as described in the Intlayer with Next.js guide,
- no
src/middleware.ts - no
generateStaticParams
src/app/layout.tsx
Copy code
Copy the code to the clipboard
src/app/page.tsx
Copy code
Copy the code to the clipboard
src/component/pageContent.ts
Copy code
Copy the code to the clipboard
src/hooks/htmlTextDir.ts
Copy code
Copy the code to the clipboard