Repository navigation
Version 3.1.1
What Changed
Added
pnpm bench:docs(scripts/update-benchmark.js): runs both bench suites twice, parses the printed tables, writestest/fixtures/bench-results.json, and regenerates theBENCHMARK.mdtables and the README## Benchmarkssummary from it — no more hand-transcribing benchmark numbers.
Changed
- The full benchmark report moved out of the README into a dedicated
BENCHMARK.md(static methodology intro and conclusion, with the two result tables wrapped in<!-- b1 -->/<!-- /b1 -->and<!-- b2 -->/<!-- /b2 -->markers). The README## Benchmarkssection is now a short summary — a one-line "X–Yx faster than the previous release / than native" range plus a link toBENCHMARK.md— so it keeps the attention on the big picture instead of the per-operation numbers. setMatrixValue()now mutates the matrix in place and returnsthis, matching the nativeDOMMatrix.setMatrixValue()(previously it returned a new matrix and left the original untouched). ThefromArray()/fromMatrix()value writers now accept an optional target instance, so the array / object paths ofsetMatrixValue()write straight into the existing instance instead of allocating a new one. Both benchmark suites gainedsetMatrixValue()operations to cover the new path: array and transform-list inputs against the 3.0.x snapshot, and a parity-checked transform-list case against native (the native parity suite now covers 22 operations).
Fixed
- The native benchmark's
transformPointcase measured asymmetric work: the shim side constructed the matrix from a transform string on every iteration while the native side reused a pre-builtDOMMatrix. Both sides now pre-build the matrix, and the corrected measurement is ~11x shim-faster ontransformPoint(previously reported as ~0.36x native-faster, see the 3.1.0 entry above);test/fixtures/bench-results.json, theBENCHMARK.mdtables and the README## Benchmarkssummary were regenerated withpnpm bench:docs.
Full Changelog: 3.1.0...3.1.1