-
Notifications
You must be signed in to change notification settings - Fork 10k
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 name 'SVGGraphics' in api.d.ts #16772
Comments
Duplicate of #16705 |
It's more likely for people to find this issue as it triggers on updates of pdf.js than The effect of this issue is that we won't be updating pdf.js until this symptom is fixed. |
Fixing this will require that a TypeScript user, such as yourself, helps out here! |
This comment was marked as duplicate.
This comment was marked as duplicate.
I found a temporary workaround for this. I created a custom type declaration: declare global {
export type SVGGraphics = any;
} |
I just rolled back to previous major version |
This comment was marked as duplicate.
This comment was marked as duplicate.
I am blocked and cannot upgrade :( have to stick with 3.8.162. |
If you don't care and want to solve this problem in the current new version, you can add in tsconfig.json:
It should be noted that when you choose to use It does solve your problem though (so far) If you feel unsafe or worried, you can roll back the version, such as the older "pdfjs-dist": "^2.4.456" If you use an old version, you can use the following code to solve the error message (*.d.ts):
|
currently the latest version of pdfjs dist doesn't work with typescript: mozilla/pdf.js#16772
Can't compile v3.9.179 in a node.js project.
Configuration:
Steps to reproduce the problem:
The text was updated successfully, but these errors were encountered: