Rxova
← All repos

ts-extended-errors

Updates mentioning ts-extended-errors. See the repository ↗ for commits and releases.

  1. ts-extended-errors 1.0.0

    ts-extended-errorsreleasebreakingts-extended-errors@1.0.0

    ts-extended-errors is 1.0. The API that shipped through 0.x is now stable: ExtendedError, defineError, the cause-chain helpers, serializeError, deserializeError, toError, isErrorLike, describeValue and the exported types. From here, a breaking change to any of them, to the serialized shape, or to the defaults of toJSON and serializeError means a new major.

    The one breaking change is the runtime floor: Node.js 22.12 or newer. The library uses no Node.js APIs, so browsers and other runtimes are unaffected.

    1.0 also types code as the literal a class declares, so a switch over a taxonomy’s codes can be exhaustive; accepts an interface as a context type; and keeps a numeric code through a JSON round trip.

    Jonatan Kruszewski

  2. Leaner builds and stricter gates across the libraries

    overlockuse-everywherejourneyreact-inputsts-extended-errorsinfra

    overlock and use-everywhere now build with tsdown instead of tsup (overlock 0.10.1, use-everywhere 1.0.1). The published output keeps its shape: same entry points, formats, filenames and types. overlock’s tarball is smaller, because code shared by its two entries is no longer duplicated.

    Every library’s CI now gates on knip and sherif. knip fails on unused files, exports and dependencies. sherif fails when two packages in a workspace disagree on a dependency’s version. The first pass removed internal exports nothing imported (overlock 0.10.2, @use-everywhere/core 1.0.2), none of them part of the public API.

    Jonatan Kruszewski

  3. ts-extended-errors is on npm and rxova.org

    ts-extended-errorsWebsiteBrandreleasedocsts-extended-errors@0.4.4

    ts-extended-errors is public. It is a zero-dependency error model for TypeScript applications that throw native exceptions but need more from them:

    • typed context: defineError, with a message option that writes the message from the context;
    • cause-chain inspection;
    • JSON round trips: serializeError and deserializeError rebuild errors as their own classes, including AggregateError.

    Install it with npm install ts-extended-errors. Every version is on npm under that name, so no .npmrc line is needed. Its docs are at /packages/ts-extended-errors/, and it appears on the rxova.org landing page.

    0.4.4 hardens the part that matters most in an error handler: a getter, proxy trap or prototype check that throws while inspecting an unknown value no longer replaces the original failure.

    Jonatan Kruszewski