Skip to content

Commit

Permalink
chore: add migration banner for apiverse
Browse files Browse the repository at this point in the history
  • Loading branch information
johannschopplich committed Apr 22, 2024
1 parent d660692 commit 75d4691
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 15 deletions.
21 changes: 9 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
# unrested
> [!TIP]
> **This is now part of [apiverse](https://github.com/johannschopplich/apiverse).**
>
> You can still use this package, but it will no longer be actively maintained. Please consider migrating to [apiverse](https://github.com/johannschopplich/apiverse). It is the spiritual successor of `unrested` and comes with many more features.
> Minimal, type-safe REST client using JS proxies.
# unrested

> [!NOTE]
> Thanks to everyone who has [upvoted this feature to be part of `ofetch`](https://github.com/unjs/ofetch/pull/69)! We closed the PR in favor of a separate upcoming package, [`api-party`](https://github.com/unjs/api-party).
Minimal, type-safe REST client using JS proxies.

## Features

Expand Down Expand Up @@ -107,7 +109,7 @@ const api = createClient({
},
async onResponseError({ request, options, error }) {
console.log('[fetch response error]', request, error)
},
}
})
```

Expand All @@ -118,16 +120,11 @@ Any fetch options on a method-level will override the default options:
```ts
const response = await api.users.get({
headers: {
'Cache-Control': 'no-cache',
},
'Cache-Control': 'no-cache'
}
})
```

## Credits

- [Ilya Komsa](https://github.com/v1vendi) for his [REST API generator](https://gist.github.com/v1vendi/75d5e5dad7a2d1ef3fcb48234e4528cb).
- [David Wells](https://github.com/DavidWells) for his [GitHub API using proxies](https://gist.github.com/DavidWells/93535d7d6bec3a7219778ebcfa437df3).

## License

[MIT](./LICENSE) License 漏 2022-PRESENT [Johann Schopplich](https://github.com/johannschopplich)
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "1.0.3",
"packageManager": "pnpm@8.15.5",
"description": "Minimal, type-safe REST client using JS proxies",
"author": "Johann Schopplich <pkg@johannschopplich.com>",
"author": "Johann Schopplich <hello@johannschopplich.com>",
"license": "MIT",
"homepage": "https://github.com/johannschopplich/unrested#readme",
"repository": {
Expand Down Expand Up @@ -46,9 +46,9 @@
"dev": "unbuild --stub",
"lint": "eslint .",
"lint:fix": "eslint . --fix",
"release": "bumpp --commit --push --tag",
"test:types": "tsc --noEmit",
"test": "vitest",
"test:types": "tsc --noEmit"
"release": "bumpp"
},
"dependencies": {
"ofetch": "^1.3.4",
Expand Down

0 comments on commit 75d4691

Please sign in to comment.