Skip to main content
0 votes
3 answers
312 views

SVG is not displayed correctly when adding it to pdfmake pdf

I have a react project with pdfmake added by yarn, a component draws a chart (svg) using d3, I use an id to get the svg. This is how I get the svg and add it to an empty document: const svgElement = ...
0 votes
0 answers
14 views

Angular v19 pdfMake cannot see its typing

In prep for an angular upgrade I've created a v19 ng instance and installed pdfMake & its typing npm package. I'm working throught the examples on the pdfMake site and using their code and I'm ...
3 votes
0 answers
269 views

pdfmake import not working in nextjs app router

I want to use pdfmake in next js backend api here is the way I'm using it. import { options } from "@/app/api/auth/[...nextauth]/options"; import { getServerSession } from "next-auth&...
27 votes
10 answers
53k views

PDFMAKE: 'Roboto-Regular.ttf' not found in virtual file system ONLY AFTER GULP

I created a simple app using knockout/bootstrap/gulp that downloads a pdf using pdfMake.js. It works fine in debug mode using VS2017. After publishing and using gulp it gives this error when run: File ...
12 votes
7 answers
21k views

Lines, circles and other shapes?

Is it possible to draw lines, circles and other shapes with pdfmake? If yes, is there a documentation or are there any samples? I would like to replace jsPDF with pdfmake.
5 votes
2 answers
25k views

Add border arround a paragraph with pdfmake

I'm generating pdf via pdfmake. Let's say i have content of the pdf like this var docDefinition = { content: [ 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam a pharetra ...
61 votes
5 answers
176k views

Why do I get an "unrecognized document structure" error when generating a PDF from HTML using pdfMake in Angularjs

I am trying to create a PDF from my HTML using pdfMake and Angular (I've also tried jsPDF and couldn't get it to work either). I tried using the following code in my Angular controller: var blob = new ...
6 votes
1 answer
5k views

How can I use pdfmake custom fonts in Angular without using the gulp tool?

The standard method for installing custom font files is via the gulp tool, and that's described here: https://pdfmake.github.io/docs/fonts/custom-fonts-client-side/ But if that fails for you, and for ...
0 votes
1 answer
100 views

"pdfMake" Bangla font breaking the word on "এ-কার"

Bangla words are breaking on 'এ-কার' after generating the PDF using pdfMake I have tried so many different fonts to check but got the same issue
0 votes
0 answers
90 views

Generate Dynamic PDF documents ( React.js & pdfMake)

Using react i want to generate dynamic PDFs the content of the PDF is very dynamic, a combo of texts, tables, columns, stacks ... and nested tables with stacks and so on ... Before I inserting a new ...
2 votes
2 answers
590 views

How to display header on first page only using PDFmake

I am trying to build a dynamic invoice using PDFmake. The issue I'm having is that the header displays perfectly on the first page and then overlaps the table I generate from the second page onwards. ...
0 votes
0 answers
266 views

I am trying to use pdfmake libraries in Angular5 and it is giving ERROR in node_modules/@types/pdfkit/index.d.ts:603:23 - error TS1110: Type expected

I tried using following import statement : import * as pdfMake from 'pdfmake/build/pdfmake'; import * as pdfFonts from 'pdfmake/build/vfs_fonts'; (pdfMake as any).vfs = pdfFonts.pdfMake.vfs; It gave ...
1 vote
2 answers
12k views

Text going off page while using pdfmake library

I am using pdfmake to get users to fill out a form and the data from that form is taken and converted into a PDF. But the issue is when a user types in a long text the text goes off page. I have ...
0 votes
1 answer
319 views

Generate PDF with NestJS typescript using pdfmake library

I wasn't able to find information about how implement this library in nest js beacuse documentation is incomplete so am letting this here, you need first npm install pdfmake --save and npm install @...
0 votes
0 answers
33 views

How to Dynamically Center Elements in a Column with pdfMake?

I'm generating a PDF using pdfMake, and I'm having trouble dynamically centering elements within a column on the page. Specifically, I want to center an image and some text within a column, but the ...

15 30 50 per page
1
2 3 4 5
38