(slug: string)
| 26 | |
| 27 | /** Browser-side write. Slugs are `[a-z0-9-]` by grammar, so no encoding. */ |
| 28 | export const writeLastOrgCookie = (slug: string): void => { |
| 29 | document.cookie = `${LAST_ORG_COOKIE}=${slug}; Path=/; Max-Age=${LAST_ORG_MAX_AGE_SECONDS}; SameSite=Lax${ |
| 30 | window.location.protocol === "https:" ? "; Secure" : "" |
| 31 | }`; |
| 32 | }; |