Packages

cookie

2.0.1 · 30 Jun 2026MIT314.8M / weekRepositoryHomepagenpmAtom feed

Your version

2.0.0

major24 Jun 2026Where it was published

2.0.1 is the newest release of 2.x.

In short

1 removed2 faster3 changed

  • removed

    Remove deprecated code paths (#272)

Release note

Important: This release moves the package to ESM only. In node 22+ you can require(esm), and older node versions are not supported.

Changed

  • Switch to ESM (#273)

  • removed

    Remove deprecated code paths (#272)

    • The old parse and stringify methods have been renamed: parseCookie and stringifySetCookie

    • stringifySetCookie only supports object mode (e.g. { name: "", value: "" })

Improvements

  • Faster stringify cookie

  • Optimize encode performance (#269)

  • Apply encode to empty cookie values (#277)

Fixed

  • Omit leading semicolon when stringifying cookies with skipped values