openapi-fetch
v0.9.0-next.0 openapi swagger rest api oapi_3 oapi_3_1 typescript fetch react and 3 more...
lint
pnpm run "/^lint:/"
test
pnpm run "/^test:/"
build
pnpm run build:clean && pnpm run build:js && pnpm run build:js-min && pnpm run build:cjs
lint:js
eslint "{src,test}/**/*.{js,ts}"
pretest
pnpm run generate-types
test:js
vitest run
test:ts
tsc --noEmit
version
pnpm run prepare && pnpm run build
build:js
mkdir -p dist && cp src/* dist
build:cjs
esbuild --bundle src/index.js --format=cjs --outfile=dist/cjs/index.cjs && cp dist/index.d.ts dist/cjs/index.d.cts
build:clean
del dist
build:js-min
esbuild --bundle src/index.js --format=esm --minify --outfile=dist/index.min.js && cp dist/index.d.ts dist/index.min.d.ts
lint:prettier
prettier --check "{src,test}/**/*"
generate-types
cd ../openapi-typescript && pnpm run build && cd ../openapi-fetch && ../openapi-typescript/bin/cli.js ./test/fixtures/api.yaml -o ./test/fixtures/v7-beta.d.ts && npx openapi-typescript ./test/fixtures/api.yaml -o ./test/fixtures/api.d.ts