@oasis-gen/win32-x64 0.1.2 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -9
- package/bin/oasis-gen.exe +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,15 +1,18 @@
|
|
|
1
|
-
<
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
<div align="center">
|
|
2
|
+
<img src="https://raw.githubusercontent.com/22mb/oasis/main/site/public/logo-512.png" alt="" width="96" height="96">
|
|
3
|
+
<h1>oasis-gen</h1>
|
|
4
|
+
<p>A minimal API client generator for <b>OpenAPI 3.2</b>.</p>
|
|
5
|
+
<p>
|
|
6
|
+
<a href="https://22mb.github.io/oasis/"><b>Documentation</b></a> ·
|
|
7
|
+
<a href="https://22mb.github.io/oasis/playground"><b>Playground</b></a> ·
|
|
8
|
+
<a href="https://22mb.github.io/oasis/ja/">日本語</a>
|
|
9
|
+
</p>
|
|
10
|
+
</div>
|
|
6
11
|
|
|
7
12
|
oasis-gen reads an OpenAPI document and writes one dependency-free TypeScript
|
|
8
13
|
file, with types for every operation and a small `fetch`-based runtime.
|
|
9
14
|
|
|
10
|
-
|
|
11
|
-
**[Playground](https://22mb.github.io/oasis/playground)** ·
|
|
12
|
-
[日本語](https://22mb.github.io/oasis/ja/)
|
|
15
|
+
<img src="https://raw.githubusercontent.com/22mb/oasis/main/site/public/strict-types.png" alt="In the generated client, res.data has the type $Pet when res.status is 200, $Error when it is 404, and unknown for any other status">
|
|
13
16
|
|
|
14
17
|
- **OpenAPI 3.2**: `QUERY` operations, sequential media types (JSON Lines,
|
|
15
18
|
server-sent events), multi-file documents, and JSON Schema 2020-12.
|
|
@@ -45,7 +48,7 @@ if (res.status === 200) {
|
|
|
45
48
|
npm install --save-dev oasis-gen
|
|
46
49
|
```
|
|
47
50
|
|
|
48
|
-
The CLI and the generated client need Node.js
|
|
51
|
+
The CLI and the generated client need Node.js 22 or later. The client also
|
|
49
52
|
runs in browsers and Bun, and type-checks with TypeScript 5.0 or later.
|
|
50
53
|
|
|
51
54
|
The package ships prebuilt binaries for macOS, Linux, and Windows, on arm64
|
package/bin/oasis-gen.exe
CHANGED
|
Binary file
|