Imposia 0.5.0
Imposia 0.5.0 parses HTML with the browser's own parser, cuts layout-measurement
work on long documents, and patches two vulnerable dependencies that were
bundled into the Core browser artifact.
This release contains one breaking change. Read
the migration note
before upgrading — most applications need no code change, but warning order,
PAGE_RULE_UNSUPPORTED.sourceIndex, and Node-side prepareDocument calls can
be affected.
Security
postcss8.5.26 and its transitivenanoid3.3.18. Both are bundled into
@imposia/core, so the exposure reached consumers rather than staying in the
toolchain — a consumer on0.4.1cannot fix this through their own lockfile.
Upgrading is the delivery path.
Breaking
- Core parses the string domain with the browser-native parser (
DOMParser,
template fragment parsing, native serialization) instead ofparse5, and
nodeOrderbecame a strided document-order slot.parse5andentities
left the Core bundle. Warnings are now ordered by post-recovery document
order,PAGE_RULE_UNSUPPORTED.sourceIndextakes different numeric values,
andprepareDocumentrequires a DOM.
Highlights
- Sibling runs are placed as chunks and bisected only on overflow, replacing a
forced synchronous reflow and an inline-overflow check per node. - Page-crossing text splits derive rendered-line boundaries from line-box rects
plus a verified search instead of oneRange.getClientRects()call per
grapheme. On long-paragraph fixtures,getClientRectscalls fell 98.1%
(English) and 95.9% (CJK). - Break-constraint capture skips the interior of atomic subtrees when the CSS
provably contains no fragmentation-relevant declarations. A heavy-SVG fixture
skipped 21,240 interior captures per pass. - Same-URL assets within one generation share a single resolver call, decode
validation, and Blob URL, without changing per-occurrence byte accounting or
the extensionallowAssetveto. - Viewer no longer throws
canonical page markers do not match pageCountwhen a
host updates a document under load. The commit was always atomic and no stale
generation was ever rendered; the transient between a commit landing and the
host delivering the newPageDocumentwas being classified as corruption.
Present since at least0.4.1and reproduced there. - Core · PageDocument is 60.0 KiB gzip — 43.6 KiB below the pre-
0.5.0route,
even though this release ships three performance escape hatches beside the
fast paths they guard. - The spread-cover visual gate compares structural geometry on all three engines
instead of checked-in Chromium/Darwin PNG baselines, which always skipped in
CI and always failed locally.
Temporary options, removed next minor
experimental.forceSequentialPlacement, experimental.forceLegacyLineEnds,
and experimental.forceFullConstraintCapture restore the implementations the
new fast paths replaced. They exist for one release so a fast path can be
disabled in the field, and they are removed in the next minor — which is why
the Core bundle carries both paths right now. If one of them is load-bearing
for your application, say so on the issue that owns its removal before that
release ships. See
the 0.x API change policy.
Install
pnpm add @imposia/react@0.5.0Framework-neutral consumers can install the package that matches their layer:
pnpm add @imposia/core@0.5.0
pnpm add @imposia/viewer@0.5.0
pnpm add @imposia/client@0.5.0All four packages move together. Mixing a 0.5.0 package with a 0.4.1 one is
not a supported combination.
Packages
Each attached .tgz is the package tarball submitted to npm. SHA256SUMS
records the matching GitHub Release asset checksums.