···11<div align="center">
22- <img alt="Hey API logo" height="150" src="https://heyapi.dev/assets/.gen/logo-astronaut-300w.png" width="150">
33- <h1 align="center"><b>Vite Plugin</b></h1>
44- <p align="center">🚀 Vite plugin for <code>@hey-api/openapi-ts</code> codegen.</p>
22+ <img alt="Hey API presents openapi-ts" height="214" src="https://heyapi.dev/assets/.gen/openapi-ts-hero-640w.png" width="438">
33+ <h1><b>Vite Plugin</b></h1>
44+ <p>Vite plugin for <code>@hey-api/openapi-ts</code>.</p>
55</div>
6677-## Dashboard
77+<p align="center">
88+ <a href="https://www.devtrends.dev/trends?c=v1.kZIAzQaO"><img src="https://api.devtrends.dev/badge/npm/%40hey-api%2Fvite-plugin?period=month&style=flat&view=value" alt="DevTrends badge for @hey-api/vite-plugin" /></a>
99+ <a href="https://www.devtrends.dev/trends?c=v1.kZIAzQaO&v=change"><img src="https://api.devtrends.dev/badge/npm/%40hey-api%2Fvite-plugin?period=year&style=flat&view=change" alt="DevTrends badge for @hey-api/vite-plugin" /></a>
1010+ <a href="https://github.com/hey-api/openapi-ts/actions?query=branch%3Amain"><img src="https://github.com/hey-api/openapi-ts/actions/workflows/ci.yml/badge.svg?event=push&branch=main" alt="CI status" /></a>
1111+ <a href="https://github.com/hey-api/openapi-ts"><img src="https://img.shields.io/github/stars/hey-api/openapi-ts?style=flat&logo=github&label=GitHub&color=54C82D" alt="GitHub stars" /></a>
1212+ <a href="https://github.com/hey-api/openapi-ts/blob/main/LICENSE.md"><img src="https://img.shields.io/github/license/hey-api/openapi-ts" alt="MIT License"></a>
1313+</p>
1414+1515+<p align="center">
1616+ <a href="https://heyapi.dev">Manual</a>
1717+ <span> • </span>
1818+ <a href="https://github.com/hey-api/openapi-ts/issues">Issues</a>
1919+ <span> • </span>
2020+ <a href="https://heyapi.dev/openapi-ts/community/contributing">Contribute</a>
2121+</p>
2222+2323+## About
2424+2525+[Vite](https://vite.dev) is a blazing fast frontend build tool powering the next generation of web applications.
2626+2727+The Vite plugin integrates [`@hey-api/openapi-ts`](https://heyapi.dev/openapi-ts) into the Vite build pipeline, running automatically whenever Vite resolves its configuration – no separate script or manual step required.
2828+2929+Part of the Hey API ecosystem.
3030+3131+## Features
83299-Access your projects and OpenAPI specifications in the [Hey API Platform](https://app.heyapi.dev/).
3333+- runs automatically as part of your Vite build
3434+- reads your existing configuration (or accepts inline config)
3535+- works with any Vite-based project
3636+- [sync with Hey API Registry](https://heyapi.dev/openapi-ts/integrations) for spec management
10371138## Contributing
1239···14411542Start with our [Contributing](https://heyapi.dev/openapi-ts/community/contributing) guide and release your first feature.
16431717-## Documentation
1818-1919-Please visit our [website](https://heyapi.dev) for documentation, guides, migrating, and more.
2020-2144## Sponsors
22452323-Help Hey API stay around for the long haul by becoming a [sponsor](https://github.com/sponsors/hey-api).
4646+Hey API is sponsor-funded. If you rely on Hey API in production, consider becoming a [sponsor](https://github.com/sponsors/hey-api) to accelerate the roadmap.
24472548<h3 align="center">Gold</h3>
2649···125148 </tbody>
126149</table>
127150151151+## Installation
152152+153153+You can download `@hey-api/vite-plugin` from npm using your favorite package manager.
154154+155155+#### npm
156156+157157+```sh
158158+npm add @hey-api/vite-plugin -D -E
159159+```
160160+161161+#### pnpm
162162+163163+```sh
164164+pnpm add @hey-api/vite-plugin -D -E
165165+```
166166+167167+#### yarn
168168+169169+```sh
170170+yarn add @hey-api/vite-plugin -D -E
171171+```
172172+173173+#### bun
174174+175175+```sh
176176+bun add @hey-api/vite-plugin -D -E
177177+```
178178+128179## Usage
129180130130-Add to `plugins` inside your Vite configuration.
181181+Add the plugin to your `vite.config.ts`:
182182+183183+```ts
184184+import { heyApiPlugin } from '@hey-api/vite-plugin';
185185+import { defineConfig } from 'vite';
186186+187187+export default defineConfig({
188188+ plugins: [heyApiPlugin()],
189189+});
190190+```
191191+192192+The plugin will automatically pick up your [configuration](https://heyapi.dev/openapi-ts/configuration) file. You can also pass options inline using the `config` option:
131193132194```ts
133195import { heyApiPlugin } from '@hey-api/vite-plugin';
196196+import { defineConfig } from 'vite';
134197135198export default defineConfig({
136199 plugins: [
137200 heyApiPlugin({
138201 config: {
139139- // optional configuration instead of using the configuration file
202202+ input: 'hey-api/backend', // sign up at app.heyapi.dev
203203+ output: 'src/client',
140204 },
141205 }),
142206 ],
143207});
144208```
209209+210210+## License
211211+212212+Released under the [MIT License](https://github.com/hey-api/openapi-ts/blob/main/LICENSE.md).