aboutsummaryrefslogtreecommitdiff
path: root/webAO/utils/setCookie.ts
blob: 084fa20096e32e60426ba587f2b492dc941d8ff9 (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}`;
};
export default setCookie;