Skip to content

Commit bdb0908

Browse files
lazzymsO2sa
authored andcommitted
feat: update data prop type in CompareForm to boolean for better type safety
1 parent 2c217d3 commit bdb0908

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

app/page.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ export default function HomePage() {
8383
loading={loading}
8484
reset={reset}
8585
swapUsers={swapUsers}
86-
data={data}
86+
data={Boolean(data)}
8787
/>
8888

8989
{loading && skeleton}

components/compare-form.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import {
1111
import { Alert, AlertDescription } from "./ui/alert";
1212

1313
type CompareFormProps = {
14-
data?: unknown;
14+
data?: boolean;
1515
onSubmit: (u1: string, u2: string) => void;
1616
loading?: boolean;
1717
reset?: () => void;

0 commit comments

Comments
 (0)