unjs / cookie-es

🍪 Cookie and Set-Cookie parser and serializer
Other
151 stars 10 forks source link

Support parsing and serializing `Set-Cookie` header #33

Closed pi0 closed 4 months ago

pi0 commented 5 months ago

Cookie-es is a rework of npm cookie package that is intended to parse Cookie header (from browser -> server)

Another format of cookie is Set-Cookie header (from server -> browser) and has different semantics for example allows single value attributes like HttpOnly (https://github.com/unjs/cookie-es/issues/17,) which are not supported nor intended for Cookie header that we support parsing for.

set-cookie-parser is a good candidate to use as bases since is already well-tested.