-
Notifications
You must be signed in to change notification settings - Fork 31
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
Error when bundling code in version 3.3.1 #98
Comments
Hi @ValYouW, thank you for raising this issue and sorry for the inconvenience. For esbuild, have you tried to alias the bson to use cjs as below. I've done a quick test in my local environment it seems to resolve this issue. You should also be able to define this from an esconfig file. We had a similar issue during our testing in which we've added an alias to the package.json which fixed this problem for a few other bundling tools, but looks like esbuild doesn't not pick up this from package.json. We are also trying to workout with the bson library team to if there can be a better solution to this. --alias:bson="./node_modules/bson/lib/bson.cjs" |
I had similar issue. I downgraded back to v.3.0.0 and seems it helped to resolve the issue for now. |
Same here. Had to downgrade to v3.2.1. |
1 similar comment
Same here. Had to downgrade to v3.2.1. |
Got the same issue with nuxt (vite) :( |
To use version For npm
For yarn
|
After upgrading to version 3.3.1 I started to get the following error when building my code (using esbuild):
It seems the error comes from
bson
lib that was updated in version3.3.1
to^5.4.0
(used to be4.5.2
in3.2.1
)The text was updated successfully, but these errors were encountered: