Files
threadcount-community/lib/plans-live.ts
T
ThreadCount 1bc2de655a ThreadCount Community edition
Uniform stock management for healthcare linen rooms. Licensed under the GNU AGPL v3.
2026-09-13 08:45:19 +10:00

13 lines
753 B
TypeScript

import { cache } from "react";
import { switches } from "./switches";
/* Whether the public site tells the plans story yet.
*
* The pricing page promised that "the rooms using it will hear before the website does", so the
* site cannot change on a deploy: it changes when the console's plans switch is turned on, after
* the notice to existing rooms has run — the same switch that starts capping new sign-ups, so the
* words and the product flip together. Cached per request: the footer, the CTA band and the page
* all ask, and one read is enough. The (site) layout revalidates every minute, so a flip reaches
* the prerendered pages within that. */
export const plansLive = cache(async (): Promise<boolean> => (await switches()).plansLive);