Skip to main content
Glama
goperigon

Perigon MCP Server

Official
by goperigon
theme.ts577 B
import { useEffect, useState } from "react"; type Theme = "light" | "dark"; export function useTheme() { const [theme, setTheme] = useState<Theme>(() => { if (typeof window !== "undefined") { return (localStorage.getItem("theme") as Theme) || "dark"; } return "dark"; }); useEffect(() => { const root = window.document.documentElement; if (theme === "dark") { root.classList.add("dark"); } else { root.classList.remove("dark"); } localStorage.setItem("theme", theme); }, [theme]); return { theme, setTheme }; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/goperigon/perigon-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server