Ignore generated OpenAPI types
This commit is contained in:
11
frontend/scripts/gen-openapi.mjs
Normal file
11
frontend/scripts/gen-openapi.mjs
Normal file
@@ -0,0 +1,11 @@
|
||||
// scripts/gen-openapi.mjs
|
||||
import { execSync } from "node:child_process"
|
||||
|
||||
const url =
|
||||
process.env.VITE_OPENAPI_URL ?? "http://127.0.0.1:8000/openapi.json"
|
||||
|
||||
console.log(`[gen:api] OpenAPI URL: ${url}`)
|
||||
|
||||
execSync(`npx openapi-typescript "${url}" -o src/generated/api.d.ts`, {
|
||||
stdio: "inherit",
|
||||
})
|
||||
Reference in New Issue
Block a user