@pubinfo/unplugin-openapi
v0.7.0
Published
Unplugin for @pubinfo/openapi.
Downloads
20
Readme
@pubinfo/unplugin-openapi
Generate request files according to the OpenAPI.
Install
# npm
npm install @pubinfo/unplugin-openapi -D
# yarn
yarn add @pubinfo/unplugin-openapi -D
# pnpm
pnpm install @pubinfo/unplugin-openapi -D
Usage
Powered by unplugin, unplugin-openapi
provides a plugin interface for bundlers.
If you are using config file, we will load config file firstly.
Vite/Rollup
// vite.config.js / rollup.config.js
import OpenAPI from '@pubinfo/unplugin-openapi/vite'
export default {
plugins: [
OpenAPI({ /* options */ })
]
}
Webpack
// webpack.config.js
import OpenAPI from '@pubinfo/unplugin-openapi/webpack'
module.exports = {
plugins: [
OpenAPI({ /* options */ })
]
}
Configuration
Same as @pubinfo/openapi