You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description="The value to compare against. The component associated with the matching key in <code>caseBy</code> will be rendered."
22
22
/>
23
23
24
24
<Interface
25
25
required
26
26
name="caseBy"
27
-
type="Record<string | number | boolean, () => JSX.Element>"
27
+
type="Partial<{ [P in StringifiedValue<Case>]: () => ReactElement | null }>"
28
28
description="An object that maps values to components to render. The keys represent possible values, and the values are functions returning the corresponding components."
29
29
/>
30
30
31
31
<Interface
32
-
required
33
32
name="defaultComponent"
34
-
type="() => JSX.Element"
33
+
type="() => ReactElement | null"
35
34
description="The component to render if <code>value</code> does not match any key in <code>caseBy</code>."
36
35
/>
37
36
38
37
### Return Value
39
38
40
39
<Interface
41
40
name=""
42
-
type="JSX.Element"
41
+
type="ReactElement | null"
43
42
description="React component that conditionally renders based on cases."
0 commit comments