unstale

npm / pdfmake

pdfmake

What changed in pdfmake 0.2 to 0.3, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-26.

10 breaking3 security20 new APIs and options1 performance3 behavior and defaults29 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli 0.2.7 on npm

pdfmake 0.361 changes

Breaking changes 8

  • Invalid color names now default to black instead of using the last valid color.

    0.3.8release notes

  • SVG validation requires width and height to be specified in the SVG string or element, or in the svg node.

    0.2.23, 0.3.2release notesrelease notes

  • Support for Internet Explorer 11 was dropped.

    0.3.0release notes

  • The interface for node and browser was unified; this is a breaking change.

    0.3.0release notes

  • Node.js 20 LTS is the minimal supported version.

    0.3.0release notes

  • The parameters of the pageBreakBefore function changed; this is a breaking change.

    0.3.0release notes

  • All methods return promises instead of using callbacks; this is a breaking change.

    0.3.0release notes

  • Virtual font storage is included in the client-side; this is a breaking change.

    0.3.0release notes

Security 3

  • Fixed local images embedded in SVG bypassing setLocalAccessPolicy.

    0.3.12release notes

  • URLs are validated before each redirection in Node.js and after the final redirection in browsers.

    0.3.8release notes

  • Adds a custom access policy for external URLs before download, addressing potential server vulnerability CVE-2026-26801.

    0.3.6release notessecurity advisory

New APIs and options 19

  • Adds horizontal table alignment with left as the default and center or right as alternatives.

    0.3.13release notes

  • Adds a server-side method for defining a custom access policy for local files.

    0.3.8release notes

  • Adds an option on text nodes to include them in bookmarks when set to true.

    0.3.5release notes

  • Adds an optional setting to show a bookmark as expanded or opened when set to true.

    0.3.5release notes

  • Adds an optional parent bookmark id for a text node's bookmark.

    0.3.5release notes

  • Adds a ToC property that adds all items to outlines or bookmarks while respecting existing outline settings on texts.

    0.3.5release notes

  • Adds an optional custom bookmark text value; otherwise the text from the node is used.

    0.3.5release notes

  • Adds a property for columns to enable newspaper-like column flow.

    0.3.5release notes

  • Table cells support vertical alignment with the values top (default), middle, and bottom.

    0.3.4release notes

  • Adds extends to a style, accepting a style name or an array of style names to inherit styles.

    0.3.3release notes

  • Adds decorationThickness to set the width of the text decoration line.

    0.3.3release notes

  • Adds hideEmpty to hide an empty ToC when set to true.

    0.3.3release notes

  • Adds sortBy to sort the ToC by page or title; page is the default.

    0.3.3release notes

  • Adds sortLocale to specify a custom locale for sorting by sortBy.

    0.3.3release notes

  • A custom markerColor can be set for each item of ul and ol.

    0.2.23, 0.3.2release notesrelease notes

  • The svg node now supports an SVGElement object, available only in the browser.

    0.2.22, 0.3.1release notesrelease notes

  • Attachments embedding was added.

    0.3.0release notes

  • Font files and images can be loaded via HTTP or HTTPS URLs in Node.js, client-side, and server-side.

    0.3.0release notes

  • A section node was added.

    0.3.0release notes

Performance 1

  • The browser bundle size was reduced by over 20%.

    0.3.12release notes

Behavior and default changes 3

  • Image scaling is supported when only height is defined.

    0.2.23, 0.3.2release notesrelease notes

  • Added automatic page height for multiple pages in a section or after a custom page break.

    0.3.1release notes

  • Parameters passed to createPdf now receive type validation.

    0.3.1release notes

Fixes and other changes 27

  • Sections no longer share the first section's automatic page height, preventing content clipping in subsequent sections.

    0.3.13release notes

  • Fixes a TypeError: Invalid base URL when loading the browser build in React Native.

    0.3.13release notes

  • Adjacent text fragments with different decorationThickness values are rendered with their respective decoration thicknesses.

    0.3.13release notes

  • PDF stream errors now reject promises returned by getBuffer(), getBase64() and getDataUrl().

    0.3.13release notes

  • Returns an unconsumed stream; subsequent stream access rejects.

    0.3.13release notes

  • Percentage widths now use correct padding and border widths when mixed with auto or star-sized columns.

    0.3.13release notes

  • Vertical alignment is corrected when a table with row-spanned header cells starts on a subsequent page.

    0.3.13release notes

  • Corrects paint order in unbreakable blocks so outer table fills no longer cover nested table fills.

    0.3.13release notes

  • Positioning and automatic thickness for mixed font sizes no longer depend on the order of text fragments.

    0.3.13release notes

  • Attachments loaded from the virtual file system, including downloaded URL attachments, no longer fail with "No src specified".

    0.3.13release notes

  • Clipping height no longer depends incorrectly on the decoration's vertical position on the page.

    0.3.13release notes

  • Reuses buffered PDF data so write() no longer hangs or fails after getBuffer(), getBase64() or getDataUrl().

    0.3.13release notes

  • RGB JPEGs are no longer embedded as DeviceGray, fixing a bug introduced in pdfkit 0.19.0.

    0.3.11release notes

  • Fixed table cell height handling for rowSpan cells in the last column.

    0.3.9release notes

  • Fixes the rowSpan ending offset across pages.

    0.3.8release notes

  • Fixes an extra blank page when headerRows, dontBreakRows and cell pageBreak are used together.

    0.3.8release notes

  • Adds validation for image height and width values.

    0.3.6release notes

  • Fixed margin inheritance when styles are extended multiple times.

    0.3.4release notes

  • Fixes margin overrides when the override value is 0.

    0.3.3release notes

  • Fixes margin overrides from multiple styles.

    0.3.3release notes

  • Fixes a TypeError caused by t.classList.contains not being a function.

    0.3.3release notes

  • Fixes text decoration for superscript and subscript.

    0.3.3release notes

  • Fixed the non-working browser method.

    0.3.2release notes

  • Fixed the non-working browser method.

    0.3.2release notes

  • Fixed SVG loading.

    0.3.1release notes

  • Fixed rendering SVG without viewBox.

    0.2.22, 0.3.1release notesrelease notes

  • The write method now waits for the file write operation to complete.

    0.3.1release notes

pdfmake 0.25 changes

Breaking changes 2

  • Parameters passed to createPdf are now validated as objects.

    0.2.22release notes

  • Parameters passed to createPdfKitDocument are now validated as objects.

    0.2.22release notes

New APIs and options 1

  • Adds the wordBreak property for text nodes, supporting normal (the default) and break-all.

    0.2.21release notes

Fixes and other changes 2