cern-next icon indicating copy to clipboard operation
cern-next copied to clipboard

Unable to export your project to host

Open MrFarhan opened this issue 3 years ago • 5 comments

I am unable to export your app using next export command, it give error i18n support is not compatible with next export..

How to export the build and host it ?

Error and package.json snapshot is attached

nexti18error

MrFarhan avatar Oct 29 '21 23:10 MrFarhan

This may help? https://dev.to/adrai/static-html-export-with-i18n-compatibility-in-nextjs-8cd

adrai avatar Jan 03 '22 10:01 adrai

Hi @adrai. I have a question. Is there any downside of this approach where he stores all the translation as javascript string, also there's no use of getStaticProps to get the locale. He uses useRouter to get the locale. As I have seen that many libraries prefer to store the translation in JSON files and to get the locale they usually implement it in getStaticProps which going to be hard to implement in terms of dynamic routes because we need to list all dynamic paths in getStaticPaths.

bryanprimus avatar Aug 03 '22 01:08 bryanprimus

This approach is kust not using any i18n framework at all. It works for simple stuff... no pluralization, no context, no interpolation, etc...

adrai avatar Aug 03 '22 05:08 adrai

This is a whole new level of scam spam 🤯

p0fi avatar Jan 25 '24 17:01 p0fi