There are a few ways to get info from an API
'''ts const response = await fetch("mysite.com/api/dogs") '''
import React from "react";
export type AllowedTypes = string | number; export type Props = { value: T; };
export function Box( props: React.PropsWithChildren<Props>, ) { return
{props.value}
; }<Box value={"10"} />; // ok. <Box value={"10"} />; // Type 'boolean' does not satisfy the constraint 'AllowedTypes'. <Box value={"10"} />; // Type 'string' is not assignable to type 'number'.