-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problems on build time #1
Comments
Sory for long response. You need update version of nodejs for solve this problem. |
I have Nodejs v14 installed, but still getting this error. Maybe the problem is that compiler does not process third-party files? |
Yep. Problem in build system. First DI drop support ES3 and compiled to ES2015. Because of this some old frameworks and build systems needs to be configured to support ES2015 in node_modules packages. As a rule, adding babel and configuring transpile in third-party packages solves this problem. |
I've solved this error by replacing 'main' key in your package.json with 'module' key. See https://webpack.js.org/guides/author-libraries/#final-steps |
Thanks for help. I add module in package.json and published new version (first-di@0.1.29). Now you can upgrade and it will work out of the box. But modules and ES2015 in main files it modern trend. And better way will fix bundle system to support this features in main files. |
This error is still there (using Next.js@10 and its default build system). When I totally remove |
I found the problem. I made test project on next.js and just like you got an error with build. This problem is due to not-perfect build configuration in next.js. To solve problem, I found this issues on oficial github of next.js: Then I made next config:
After that, the problem was solved. |
Added to the build is a version of the build with commonjs modules. Please try. |
Trying to use this lib as described in readme, but got this error on build time:
The text was updated successfully, but these errors were encountered: