-
-
Notifications
You must be signed in to change notification settings - Fork 281
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
Cannot find module 'node:buffer #372
Comments
Problem solved.
After those changes, mailparser worked like a charm. For details what to replace, see the issue linked above. |
Running against this issue too with webpack
|
Yes, @crest-daksh, I'm with you. This problem must be solved on the rpm repo, but I'm not skilled to maintain a GitHub source neither publish a new release to the npm repo. Obviously, neither are you. That's why I re-opened this issue a couple of weeks ago: The issue is not solved. So long, you and others may be happy to find a temporary solution at least. |
What's your runtime environment ? I'm using Cypress and it seems like it's being bundled with webpack and run in the browser which causes the issue. "mailparser is Node.js only library, so you can't use it reliably in the front-end or bundle with WebPack. If you do need a solution to parse emails in the front-end then use PostalMime." |
@Lezzio Who are you adressing with your question?
This Issue #372 is about using mailparser with node. |
@wintifrosch Why would you use webpack for a node app ? In my case it's because I run Cypress that I bundle my js for the browser using webpack |
After loading mailparser with
require('mailparser')
, I get an "Uncaught Error: Cannot find module 'node:buffer'".I tried on different servers (though all with Node.js v14.17.6.), with older versions of mailparser, and with installing buffer explicitly. The error persists.
Has anyone any tips for me, please?
The text was updated successfully, but these errors were encountered: