question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TypeError: default.a.convert is not a function

See original GitHub issue

Hi, I am facing an issue with the latest version of jspdf in the react project.

This is an error that I am getting in the console.

jspdf.es.min.js:128 Uncaught (in promise) TypeError: _babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0___default.a.convert is not a function
at new t (jspdf.es.min.js:128)

And, here is a code snippet using the latest version -

image image

I tried adding the below packages as external in the webpack, which also didn’t help.

canvg, html2canvas, dompurify

Also, the same code snippet works when I downgraded the version to 2.3.1.

Pls, suggest if there is something I am missing as I am aiming to use the latest one.

Thanks

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:6
  • Comments:10

github_iconTop GitHub Comments

1reaction
nikhil-varmacommented, Mar 16, 2022

Any update on the resolution for this?

1reaction
michaelolson1996commented, Feb 18, 2022

I am currently having this issue, I am on the current version and have tried downgrading as well as adding the .babelrc.json file to my root project folder. Any updates to a resolution?

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeError: "x" is not a function - JavaScript - MDN Web Docs
The JavaScript exception "is not a function" occurs when there was an attempt to call a value from a function, but the value...
Read more >
react__WEBPACK_IMPORTED_...
javascript - TypeError: react__WEBPACK_IMPORTED_MODULE_0___default(...) is not a function - Stack Overflow. Stack Overflow for Teams – Start collaborating and ...
Read more >
is not a function or its return value is not iterable in ReactJs ...
TypeError : react__WEBPACK_IMPORTED_MODULE_0_default is not a function or its return value is not iterable 1 | import useState from 'react'; ...
Read more >
TypeError: then is not a function in JavaScript | bobbyhadz
The "then is not a function" error occurs when the then() method is called on a value that is not a promise. To...
Read more >
How to Handle JavaScript Uncaught TypeError: “x” is Not a ...
The Javascript error TypeError: "x" is not a function occurs when there is an attempt to call a function on a value or...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found