MCPcopy Create free account
hub / github.com/agentsmd/agents.md / copyToClipboard

Function copyToClipboard

components/CodeExample.tsx:136–144  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

134 const [copied, setCopied] = React.useState(false);
135
136 const copyToClipboard = async () => {
137 try {
138 await navigator.clipboard.writeText(md);
139 setCopied(true);
140 setTimeout(() => setCopied(false), 2000);
141 } catch (err) {
142 console.error("Failed to copy to clipboard:", err);
143 }
144 };
145
146 const content = (
147 <>

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected