Open brunoscopelliti opened 1 year ago
It is curious because it only runs during build, not in runtime. But well, put it in dependencies for now and I will investigate why it happens, because it shouldn't be necessary. Thanks @brunoscopelliti to report it
If I understand correctly, when the production server starts, it loads next.config.js
. the webpack
function is not executed, but the module is required at the beginning of the file anyway. So, in theory, all next.js plugins should be declared in dependencies
Thanks for the clarification @StLyn4
We also ended in the devDependency trap, maybe someone could update this error message when running the app without next-translate-plugin installed:
What version of this package are you using?
What operating system, Node.js, and npm version?
Docker image
What happened?
After building next.js project I delete the dev dependencies, and start the project. When I start the project i get this error:
I fixed the problem, installing
next-translate-plugin
as a normal dependency, but this surprised me a bit cause in the readme it is stated thatnext-translate-plugin
is a dev dependency.What did you expect to happen?
I didn't expect to have to keep
next-translate-plugin
around after building the project.