rtk-query
const result = trpc.endpoint.useQuery(param ? { param } : skipToken)
skipToken
useQuery
const result = trpc.endpoint.useQuery({ param }, { enabled: !!param })
{ param: undefined }