-
Notifications
You must be signed in to change notification settings - Fork 4.7k
jsPDF build failed with create-react-app #3043
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
Comments
Please state exactly which versions work and which versions don't. Please also provide a small repro. Otherwise we can't help you. |
Can't reproduce. What I did is:
-> works I added this code to
|
Im also facing this issue. Try with 2.1.0 or 1.5.3 version it's working good |
I had the same problem, I downgrade the version to "jspdf": "2.0.0" and works fine in Vercel
|
@jfajardo, @akkravikumar Please attach or link to a small project that reproduces the issue, otherwise we can't help you. |
Maybe this log will be helpful to found issue Update: looks this fails in strict mode https://github.com/MrRio/jsPDF/blob/master/src/libs/md5.js#L214 |
@mititch thanks, this helped. We probably just need to rewrite this code a little. E.g.
However, we need to move it to the top of the file then probably. @mititch could you prepare a PR for this? |
Hello @HackbrettXXX, @mititch are there any plans to introduce changes resolving this issue? |
I currently don't have the time to do it myself, but I will merge a pull request. |
I made a pull request: #3173 |
This issue is stale because it has been open 90 days with no activity. It will be closed soon. Please comment/reopen if this issue is still relevant. |
I'm using jsPDF in my react application. When I try to use command

npm run build
to build my application but I got this errorI'm using version
2.1.0
. I also had tried to upgrade to newest version but I still have same error. I have a quick look into filejspdf.es.min.js
and I saw it was difference to previous stable build before 13 days ago. Before that I had no problemPlease help me to solve this problem
The text was updated successfully, but these errors were encountered: