Attempting to convert a basic html table into a PDF format within my project has resulted in unexpected errors when using CodeSandbox:
ERROR TypeError: html2canvas_1.default is not a function
at AppComponent.downloadPDF (https://3d3bh.csb.app/src/app/app.component.ts:66:30)
at new AppComponent (https://3d3bh.csb.app/src/app/app.component.ts:62:14)
Displayed below is the content of app.component.html
<!DOCTYPE html>
<html lang="en">
<head>
<title>Bootstrap Example</title>
...
The component file app.component.ts consists of code for initializing the download process and defining sample purchase data. The objective is to automatically trigger the download of the PDF document once the .ts file loads.
To view the entire project and detailed error logs, visit: https://codesandbox.io/s/jolly-bhabha-3d3bh