Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/modern-colts-hang.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@hey-api/openapi-ts': patch
---

feat(plugin): add `@pinia/colada` plugin
23 changes: 23 additions & 0 deletions .changeset/olive-pots-rest.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
'@hey-api/openapi-ts': minor
---

feat(parser): add Hooks API

### Added Hooks API

This release adds the [Hooks API](https://heyapi.dev/openapi-ts/configuration/parser#hooks), giving you granular control over which operations generate queries and mutations. As a result, we tightened the previous behavior and POST operations no longer generate queries by default. To preserve the old behavior, add a custom matcher.

```js
export default {
input: 'hey-api/backend', // sign up at app.heyapi.dev
output: 'src/client',
parser: {
hooks: {
operations: {
isQuery: (op) => (op.method === 'post' ? true : undefined),
},
},
},
};
```
8 changes: 4 additions & 4 deletions docs/.vitepress/config/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -173,12 +173,12 @@ export default defineConfig({
collapsed: true,
items: [
{
link: '/openapi-ts/plugins/tanstack-query',
text: 'TanStack Query',
link: '/openapi-ts/plugins/pinia-colada',
text: 'Pinia Colada',
},
{
link: '/openapi-ts/plugins/pinia-colada',
text: 'Pinia Colada <span data-soon>soon</span>',
link: '/openapi-ts/plugins/tanstack-query',
text: 'TanStack Query',
},
{
link: '/openapi-ts/plugins/swr',
Expand Down
10 changes: 10 additions & 0 deletions docs/data/people.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,17 @@ export const jacobCohen: Person = {
name: 'Jacob Cohen',
};

export const joshHemphill: Person = {
github: 'https://github.com/josh-hemphill',
name: 'Josh Hemphill',
};

export const maxScopp: Person = {
github: 'https://github.com/max-scopp',
name: 'Max Scopp',
};

export const sebastiaanWouters: Person = {
github: 'https://github.com/SebastiaanWouters',
name: 'Sebastiaan Wouters',
};
Loading
Loading