blob: f9ac5d2fa1f6b93d86acd5e77645bb22e18c1e74 (
plain)
1
2
3
4
5
6
7
8
9
10
|
/**
* set a cookie
* the version from w3schools expects these to expire
* @param {String} cname The name of the cookie to return
* @param {any} value The value of that cookie option
*/
const setCookie = (cname: String, value: any) => {
document.cookie = `${cname}=${value};SameSite=Strict`;
};
export default setCookie;
|