refactor: replace button elements with Button component

This commit is contained in:
Anish Sarkar 2026-05-14 14:46:48 +05:30
parent da55c75e5e
commit 13b2e874f6
7 changed files with 38 additions and 16 deletions

View file

@ -45,11 +45,12 @@ function StaticContent() {
**For mutations:**
```tsx
import { Button } from '@/components/ui/button'
import { useSWRMutation } from 'swr/mutation'
function UpdateButton() {
const { trigger } = useSWRMutation('/api/user', updateUser)
return <button onClick={() => trigger()}>Update</button>
return <Button onClick={() => trigger()}>Update</Button>
}
```