forked from vanielf/pdf-lib
-
Notifications
You must be signed in to change notification settings - Fork 29
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 embeding png #72
Labels
Comments
strangely enough it doesn't happen running with bun, only nodejs (v20, v22) |
original pdf-lib doesn't encounter this issue FYI |
Which version of Node did you use? |
happens on node 18, 20, and 22 |
To solve the issue, we would probably need to solve this problem: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What were you trying to do?
Embed png file into page
How did you attempt to do it?
file is buffer, attached
What actually happened?
2024-10-17 01:54:06.455 ERROR Invoke Error {"errorType":"TypeError","errorMessage":"dV.default.decode is not a function","stack":["TypeError: dV.default.decode is not a function"," at new PNG (/node_modules/@cantoo/pdf-lib/src/utils/png.ts:51:23)"," at pngData (/node_modules/@cantoo/pdf-lib/src/utils/png.ts:41:42)"," at Function.for (/node_modules/@cantoo/pdf-lib/src/core/embedders/PngEmbedder.ts:12:21)"," at a.embedPng (/node_modules/@cantoo/pdf-lib/src/api/PDFDocument.ts:1113:40)"
What did you expect to happen?
added successfully
How can we reproduce the issue?
file is buffer, attached
Version
2.2.3
What environment are you running pdf-lib in?
Node
Checklist
Additional Notes
No response
The text was updated successfully, but these errors were encountered: