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
{{ message }}
This repository was archived by the owner on Sep 6, 2024. It is now read-only.
Originally posted by ognis1205 July 26, 2024
The URL paths, requests, and responses of the backend server to be used are strictly defined by the OpenAPI specification.
I think it is better to automatically generate TypeScript interfaces from OpenAPI and then define the paths as union types and the requests and responses as interfaces synchronized with the OpenAPI specification using utility types.
Additionally, rather than using fetch, if you use third-party libraries like axios and implement some utilities, you can implement everything in a type-safe manner with interfaces synchronized with OpenAPI in a single API.