Skip to content
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

为什么引用pdfh5之后报错 #168

Open
whatlin opened this issue Aug 8, 2023 · 5 comments
Open

为什么引用pdfh5之后报错 #168

whatlin opened this issue Aug 8, 2023 · 5 comments

Comments

@whatlin
Copy link

whatlin commented Aug 8, 2023

image

@alinquan
Copy link

插个眼,遇到同样的问题

@cicilyxx
Copy link

解决了吗,遇到了同样的问题

@chanwingwah
Copy link

我最近也有这个问题,我选择固定回1.4.2版本解决了

解决了吗,遇到了同样的问题

@OnArrow
Copy link

OnArrow commented Sep 3, 2023

我之前用的node版本14的也报错,把node版本升级到18就没报错了

@baixjian
Copy link

System:
OS: macOS 14.2.1
CPU: (10) arm64 Apple M1 Pro
Memory: 173.05 MB / 16.00 GB
Shell:
version: "5.9"
path: /bin/zsh
Binaries:
Node:
version: 18.19.0
path: ~/.nvm/versions/node/v18.19.0/bin/node
Yarn:
version: 1.22.21
path: ~/.nvm/versions/node/v18.19.0/bin/yarn
npm:
version: 10.2.3
path: ~/.nvm/versions/node/v18.19.0/bin/npm

Could not resolve "canvas"

node_modules/pdfh5/js/pdf.js:22:244110:
  22 │ ...{key:"_createCanvas",value:function _createCanvas(t,r){return require("canvas").createCanvas(t,r)}}]);return NodeCanvasFactory}(o.BaseCanvasFactory)...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants