NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
npm · #4973 most downloaded on npm
An advanced text layout framework
Last release 1 months ago
24 Aug 2026
Release timing varies
gaps range from 2 weeks to 10 months
Some releases are documented
notes for 22 of 44 stable releases
3 versions withdrawn
withdrawn after publishing
8 years old
47 releases · first in 2018
Patch Changes #3524 df39d4cf2f18ee234b4f6c7674d94bdfc4742489 Thanks @diegomura ! - perf: merge run attributes lazily in flatten, only when a segment i
#3524 df39d4cf2f18ee234b4f6c7674d94bdfc4742489 Thanks @diegomura! - perf: merge run attributes lazily in flatten, only when a segment is emitted
#3527 6dc0901c26354dc5a38ed302ef76d371d74d8d61 Thanks @diegomura! - perf: drop the omit('font') preprocessing pass, skip attachment purging when no attachment is set, reduce allocations in the Knuth-Plass main loop, and cache standard font AFM glyph-name lookups
#3523 a291d4fb45b6260861868b973b24e9a49915f6a0 Thanks @diegomura! - perf: reduce allocation churn in text layout hot paths (~15% faster layout of text-heavy documents)
One column per quarter.
Nothing published for this version
Nothing published for this version
### Patch Changes - #3489 `6f94a82ea4306b0fd9c7c161f9c44609be7f6f39` Thanks @wojtekmaj! - Improve Knuth-Plass line breaking performance for long parag
6f94a82ea4306b0fd9c7c161f9c44609be7f6f39 Thanks @wojtekmaj! - Improve Knuth-Plass line breaking performance for long paragraphs.### Minor Changes - #3423 `06c188bd` Thanks @exoego! - fix(textkit): treat surrogate pairs as single code points in font substitution ### Patch Change
Nothing published for this version
### Minor Changes - #3358 `7b37bc8c` Thanks @diegomura! - feat(textkit): glyph indices resolution - #3355 `b28b61cf` Thanks @diegomura! - feat(textkit
#3358 7b37bc8c Thanks @diegomura! - feat(textkit): glyph indices resolution
#3355 b28b61cf Thanks @diegomura! - feat(textkit): decompose unicode step
#3357 f30cf001 Thanks @diegomura! - fix(textkit): string indices resolution
#3354 7fa9c06e Thanks @diegomura! - refactor(textkit): rename glyphIndices to stringIndices
Updated dependencies \[`c40bfdec`, `5b6a6a4a`]:
#3273 16cf5bd7 Thanks @diegomura! - feat(textkit): various improvements
#3240 2ca8ae83 Thanks @Pasquale007! - fix: cannot read units for Em
Updated dependencies [c40bfdec, 5b6a6a4a]:
Caution: If you have been using a custom hyphenation callback - which hasn't been working properly since at least version 2.0.21 - then you will need
#3188 f034491b Thanks @carlobeltrame! - Fix and rework the hyphenation algorithm, and allow custom word hyphenation algorithms to specify whether a hyphen should be inserted in case the word is wrapped.
Caution: If you have been using a custom hyphenation callback - which hasn't been working properly since at least version 2.0.21 - then you will need to change your implementation to leave a soft hyphen character ('\u00AD') at the end of syllables where you want react-pdf to insert a hyphen when wrapping lines. Syllables without a final soft hyphen character will still be able to break, but will not produce a hyphen character at the end of the line.
This allows you to break correctly on normal hyphens or other special characters in your text. For example, to use the default english-language syllable breaking built into react-pdf, but also break after hyphens naturally occurring in your text (such as is often present in hyperlinks), you could use the following hyphenation callback:
import { Font } from "@react-pdf/renderer";
Font.registerHyphenationCallback((word, originalHyphenationCallback) => {
return originalHyphenationCallback(word).flatMap((w) => w.split(/(?<=-)/));
});
(flatMap requires at least ES2019)
f89f75c1 Thanks @diegomura! - feat: add xLinkHref, gradientTransform and gradientUnits supportf89f75c1]:
Spot color names are now escaped as PDF Name objects, so names containing spaces or delimiters (e.g. PANTONE 123 C) no longer emit a malformed Separat
4c4e7a1a Thanks @diegomura! - Use generated AFM font data instead of parsing raw font definitions, and split the node and browser entry points, aligning with upstream pdfkit#3468 78ca6aa8 Thanks @diegomura! - Align structure_element.js with upstream pdfkit
#3410 87911560 Thanks @exoego! - refactor: align mulptiles filesWith upstream
#3476 62c97745 Thanks @diegomura! - refactor(pdfkit): align annotations.js, attachments.js and spotcolor.js with upstream
Spot color names are now escaped as PDF Name objects, so names containing
spaces or delimiters (e.g. PANTONE 123 C) no longer emit a malformed
Separation color space.
#3453 6098e648 Thanks @afonsojramos! - Declare the pako runtime dependency externalized by the browser build so it resolves with strict package managers.
#3431 59aa9aea Thanks @5000164! - fix(pdfkit): deflate decoded PNG pixels as Buffer
#3401 d41a8207 Thanks @diegomura! - refactor(pdfkit): replace events import in line_wrapper.js with inline emitter
#3470 b2acd72b Thanks @diegomura! - refactor(pdfkit): align page.js and document.js with upstream
#3400 c2da5098 Thanks @diegomura! - refactor(pdfkit): use byte-level PNG magic check in image.js
#3398 30dc2a47 Thanks @diegomura! - refactor(pdfkit): remove Buffer dependency from EXIF orientation parser
#3469 6e0102db Thanks @diegomura! - refactor(pdfkit): align line_wrapper.js with upstream
ddfa3675 Thanks @diegomura! - feat(textkit): expect font array#3102 24690f52 Thanks @diegomura! - feat: handle standard fonts in fonts package
#3103 b06d3a0f Thanks @diegomura! - refactor: unify font substitution engines
c7b74963 Thanks @diegomura! - fix: resolve attachments
#3098 bfb51ec0 Thanks @diegomura! - refactor: convert render package to TS
#3092 481b536f Thanks @diegomura! - refactor: convert layout package to TS
Updated dependencies [481b536f]:
24fe4bf8 Thanks @diegomura! - feat: rework and type stylesheet packageUpdated dependencies \[`24fe4bf8`, `442ce355`, `3007d34a`]:
Updated dependencies \[`d36ace66`]:
d36ace66]:
### Patch Changes - #2975 `00bfdc1e` Thanks @daslaf! - fix issue with indentation shrinking all lines
77e480cd Thanks @diegomura! - feat: accept commas between transformationsUpdated dependencies \[`70f29a04`]:
70f29a04 Thanks @diegomura! - feat!: drop cjs support70f29a04]:
Updated dependencies \[`e585e352`]:
#3351 e585e352 Thanks @diegomura! - fix(render): border rendering + tests
Updated dependencies [e585e352]:
#3152 beaffd3d Thanks @Namchee! - chore: replace emoji-regex with emoji-regex-xs
#3190 a99d10fb Thanks @carlobeltrame! - Fix yoga error Invalid array length at Array.push(<anonymous>)
Fix infinite loop while wrapping pages
#3203 ec063bec Thanks @100Gyeon! - fix: prevent unhandled promise rejections when loading emoji images
Updated dependencies []:
#2605 f7505ed Thanks @wojtekmaj! - fix: fix CJS compatibility
Updated dependencies [f7505ed]:
Updated dependencies \[`f89f75c1`]:
f89f75c1 Thanks @diegomura! - feat: add xLinkHref, gradientTransform and gradientUnits supportf89f75c1]:
8350154 Thanks @diegomura! - feat: bidi support8350154]:
`01b4ff5c` Thanks @diegomura! - fix: debug prop
f89f75c1 Thanks @diegomura! - feat: add xLinkHref, gradientTransform and gradientUnits support01b4ff5c Thanks @diegomura! - fix: debug prop
Updated dependencies [01b4ff5c, f89f75c1, 106699e8]:
#3100 a9ef6416 Thanks @diegomura! - feat: support percentage gap
#3102 24690f52 Thanks @diegomura! - feat: handle standard fonts in fonts package
#3092 481b536f Thanks @diegomura! - refactor: convert layout package to TS
#3103 b06d3a0f Thanks @diegomura! - refactor: unify font substitution engines
#3104 ddfa3675 Thanks @diegomura! - feat(textkit): expect font array
#3098 bfb51ec0 Thanks @diegomura! - refactor: convert render package to TS
#3101 fce45ea5 Thanks @diegomura! - fix: layout package types
Updated dependencies [2a4f1bfc, 7cd66e4f, ddfa3675, 3fb01a90, c7b74963, bfb51ec0, 24690f52, 481b536f, b06d3a0f]:
b6a14fd Thanks @wojtekmaj! - Add support for native ESMb6a14fd]:
### Patch Changes - Updated dependencies \[]: - @react-pdf/types@2.8.2
Updated dependencies \[`7cd66e4f`, `ddfa3675`, `c7b74963`, `bfb51ec0`, `24690f52`, `481b536f`, `b06d3a0f`]:
#3098 bfb51ec0 Thanks @diegomura! - refactor: convert render package to TS
#3102 24690f52 Thanks @diegomura! - feat: handle standard fonts in fonts package
18834efa Thanks @nikischin! - Changed unit behavior according to PDF spec. Please note that all unitless values are considered as user unit which is a 72dpi equality of the value. This is according to PDF spec and ensures a consistent layout independent of the dpi setting.18834efa]:
7cd71714 Thanks @diegomura! - feat: added Form Annotation support#3014 685890bd Thanks @islam-kamel! - fix: PDFDownloadLinkProps Type Error
Updated dependencies [7cd71714, fabecc56, 01944231, 6d875056, 49daae8f, 5cc47319, aa0f6725]:
b6a14fd Thanks @wojtekmaj! - Add support for native ESM#2498 6bfe7e8 Thanks @diegomura! - fix: color parse error
Updated dependencies [b6a14fd]:
2db67a3 Thanks @KODIKAS-NL! - added base support for verticalAlign "super" and "sub"eff1ff0]:
### Patch Changes - #3067 `96c2464d` Thanks @diegomura! - refactor: convert primitives package to TS
96c2464d Thanks @diegomura! - refactor: convert primitives package to TSd36ace66]:
#2947 ed562b9b Thanks @diegomura! - feat: remove cross-fetch
Updated dependencies [ed562b9b, 77e480cd]:
82192b3a]:
#3527 6dc0901c26354dc5a38ed302ef76d371d74d8d61 Thanks @diegomura! - perf: drop the omit('font') preprocessing pass, skip attachment purging when no attachment is set, reduce allocations in the Knuth-Plass main loop, and cache standard font AFM glyph-name lookups
Updated dependencies []:
Caution: If you have been using a custom hyphenation callback - which hasn't been working properly since at least version 2.0.21 - then you will need
#3188 f034491b Thanks @carlobeltrame! - Fix and rework the hyphenation algorithm, and allow custom word hyphenation algorithms to specify whether a hyphen should be inserted in case the word is wrapped.
Caution: If you have been using a custom hyphenation callback - which hasn't been working properly since at least version 2.0.21 - then you will need to change your implementation to leave a soft hyphen character ('\u00AD') at the end of syllables where you want react-pdf to insert a hyphen when wrapping lines. Syllables without a final soft hyphen character will still be able to break, but will not produce a hyphen character at the end of the line.
This allows you to break correctly on normal hyphens or other special characters in your text. For example, to use the default english-language syllable breaking built into react-pdf, but also break after hyphens naturally occurring in your text (such as is often present in hyperlinks), you could use the following hyphenation callback:
import { Font } from "@react-pdf/renderer";
Font.registerHyphenationCallback((word, originalHyphenationCallback) => {
return originalHyphenationCallback(word).flatMap((w) => w.split(/(?<=-)/));
});
(flatMap requires at least ES2019)
7cd71714 Thanks @diegomura! - feat: added Form Annotation support#3062 5cc47319 Thanks @diegomura! - refactor: unify pdfkit image mixin
Updated dependencies [7cd71714, 01944231]:
52b2f253 Thanks @diegomura! - feat: add React 19 support52b2f253]:
Updated dependencies \[`7cd66e4f`]:
24690f52 Thanks @diegomura! - feat: handle standard fonts in fonts package#3087 7cd66e4f Thanks @diegomura! - fix: font exported types
#3093 a2de2685 Thanks @diegomura! - refactor: font strict type checking
#3092 481b536f Thanks @diegomura! - refactor: convert layout package to TS
Updated dependencies [7cd66e4f]:
70f29a04 Thanks @diegomura! - feat!: drop cjs supportafe4bcfe Thanks @diegomura! - feat: add gap percentage support70f29a04 Thanks @diegomura! - feat!: drop cjs support#2877 fdcef566 Thanks @Friendseeker! - chore: bump jay-peg
Updated dependencies [70f29a04]:
#2711 42570321 Thanks @wojtekmaj! - Update Yoga to 3.0
#2871 70f29a04 Thanks @diegomura! - feat!: drop cjs support
#2876 afe4bcfe Thanks @diegomura! - feat: add gap percentage support
#2875 46c3047d Thanks @diegomura! - feat: add position: static support
#2874 55973278 Thanks @diegomura! - feat: add align-content: space-evenly support
Updated dependencies [`627acbe0`]:
#3464 8c723cca Thanks @diegomura! - Declare @react-pdf/primitives dependency.
Updated dependencies [627acbe0]:
70f29a04 Thanks @diegomura! - feat!: drop cjs support70f29a04 Thanks @diegomura! - feat!: drop cjs support#2877 fdcef566 Thanks @Friendseeker! - chore: bump jay-peg
Updated dependencies [70f29a04]:
### Minor Changes - #2409 `b6a14fd` Thanks @wojtekmaj! - Add support for native ESM
b6a14fd Thanks @wojtekmaj! - Add support for native ESMNothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
### Major Changes - #3224 `fafbcb12` Thanks @ZandercraftGames! - feat: add React 19.2.X support ### Patch Changes - #3261 `2eba70bd` Thanks @Nukem154!
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →