My personal frontend starter
Install bun
Then run:
bun i
bun dev
Included is a way to generate a TanStack query client using OpenAPI TypeScript
Adjust synchronization script and fetchClient
to point to your OpenAPI spec before running the sync:
// package.json
{
"scripts": {
// Update this
"sync": "bun run openapi-typescript http://localhost:8888/openapi.json -o ./src/api/schema.d.ts"
}
}
// src/api/index.tsx
const fetchClient = createFetchClient<paths>({
// Update this
baseUrl: "http://localhost:8888/",
});
bun sync
net/http
+ Huma + Goth