MCPcopy Create free account
hub / github.com/codeaashu/claude-code / useToastStore

Function useToastStore

web/components/ui/toast.tsx:57–65  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

55}
56
57function useToastStore() {
58 const [toasts, setToasts] = React.useState<ToastData[]>([])
59 React.useEffect(() => {
60 setToasts([...toastList])
61 listeners.add(setToasts)
62 return () => { listeners.delete(setToasts) }
63 }, [])
64 return toasts
65}
66
67// ── Style variants ────────────────────────────────────────────────────────────
68

Callers 1

ToastProviderFunction · 0.85

Calls 2

deleteMethod · 0.65
addMethod · 0.45

Tested by

no test coverage detected