@igniter-js/cli 0.4.91 → 0.4.93
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 +19 -0
- package/dist/index.mjs +490 -71
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -1
package/README.md
CHANGED
|
@@ -129,6 +129,20 @@ igniter generate schema --router src/igniter.router.ts --output src/igniter.sche
|
|
|
129
129
|
|
|
130
130
|
Generates a TypeScript client schema (const assertion + type) that mirrors your server endpoints.
|
|
131
131
|
|
|
132
|
+
### `igniter generate caller`
|
|
133
|
+
|
|
134
|
+
Generate Zod schemas and a ready-to-use Igniter Caller from an OpenAPI 3 spec.
|
|
135
|
+
|
|
136
|
+
```
|
|
137
|
+
# Remote spec
|
|
138
|
+
igniter generate caller --name facebook --url https://api.example.com/openapi.json
|
|
139
|
+
|
|
140
|
+
# Local spec
|
|
141
|
+
igniter generate caller --name billing --path ./openapi.yaml --output src/callers/billing
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
Outputs `schema.ts` (Zod schemas with the provided prefix) and `index.ts` (preconfigured caller) under `src/callers/<hostname>` by default, ready to use with `@igniter-js/caller`.
|
|
145
|
+
|
|
132
146
|
### `igniter dev`
|
|
133
147
|
|
|
134
148
|
Watch mode that keeps schema and docs regenerated while proxying your application’s dev server.
|
|
@@ -241,3 +255,8 @@ MIT © Felipe Barcelos and the Igniter.js contributors.
|
|
|
241
255
|
|
|
242
256
|
|
|
243
257
|
|
|
258
|
+
|
|
259
|
+
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
|