
This is a collection of functions for working with HTTP cookies.
The serializeCookie function serializes a cookie name-value pair into a string suitable for use in a Set-Cookie header or document.cookie property.
import { serializeCookie } from '@aracna/core';
// will log "a=0"
console.log(serializeCookie('a', '0'));The deserializeCookie function deserializes a cookie string to an object.
import { deserializeCookie } from '@aracna/core';
// will log { a: "0" }
console.log(deserializeCookie('a=0'));