MCPcopy Create free account
hub / github.com/code100x/daily-code / handleFilterButton

Function handleFilterButton

apps/web/components/admin/AddTrackCard.tsx:20–26  ·  view source on GitHub ↗
(category: string)

Source from the content-addressed store, hash-verified

18 const { toast } = useToast();
19
20 function handleFilterButton(category: string) {
21 if (selectedCategory.includes(category)) {
22 setSelectedCategory(selectedCategory.filter((item) => item !== category));
23 } else {
24 setSelectedCategory([...selectedCategory, category]);
25 }
26 }
27
28 return (
29 <div>

Callers 1

AddTrackCardFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected