aralroca / next-translate-plugin

Next-translate plugin for i18n in Next.js 🌍 - Load page translations and use them in an easy way!
MIT License
31 stars 18 forks source link

Critical dependency: the request of a dependency is an expression #9

Closed GenisDiaz closed 1 year ago

GenisDiaz commented 1 year ago

What version of this package are you using? 2.0.2 What operating system, Node.js, and npm version?

What happened?

When I use nextTranslate in the next.config.js then I see the message Critical dependency: the request of a dependency is an expression in the console when I try to run the app, then the translations are not working at all.

I'm using the newest nextjs 13.2.4 version with the appDir functionality instead of pages.

I don't know if I'm doing something wrong or maybe it's something new in the newest version because in other apps with older nextjs version I'm using next-translation instead of next-translation-plugin and the other ones are working good.

aralroca commented 1 year ago

I tried to reproduce it in the latest version and I can't reproduce it. Maybe is solved with this related issue: https://github.com/aralroca/next-translate-plugin/pull/32 Can you confirm that now is working for your in the latest version? Thanks!

bluelakee02 commented 1 year ago

I created a fix https://github.com/aralroca/next-translate-plugin/pull/72 Here is a patch if somebody needs it right away https://github.com/bluelakee02/next-translate-plugin-patch

zakidze commented 1 year ago

I created a fix #72 Here is a patch if somebody needs it right away https://github.com/bluelakee02/next-translate-plugin-patch

HERRROOOOOOO

aralroca commented 1 year ago

Already available in 2.6.1 👍 Thanks for the contribution @bluelakee02