Contract
Build your app with contract-first approach
Installation
Define the Contract
The API almost the same as the server
except that contract will not define the handler.
Implement the Contract
All server
features are available, except the input, output, and route parts, which are defined in the contract.
Infer Contract Router Inputs and Outputs
The InferContractRouterInputs
and InferContractRouterOutputs
type utilities can be used to infer the input and output types of a router, respectively.