@powerlines/plugin-openapi 0.2.683 → 0.2.684
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 +28 -0
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -74,6 +74,34 @@ A Powerlines plugin to generate project code with [OpenAPI](https://openapis.org
|
|
|
74
74
|
|
|
75
75
|
<!-- END doctoc -->
|
|
76
76
|
|
|
77
|
+
## Features
|
|
78
|
+
|
|
79
|
+
- Generates project code from OpenAPI specifications.
|
|
80
|
+
- Writes generated clients to a configured `outputPath`.
|
|
81
|
+
- Regenerates output after the spec changes.
|
|
82
|
+
|
|
83
|
+
## Usage
|
|
84
|
+
|
|
85
|
+
Install the package:
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
pnpm add @powerlines/plugin-openapi
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
Register the plugin in `powerlines.config.ts`:
|
|
92
|
+
|
|
93
|
+
```ts
|
|
94
|
+
import { defineConfig } from "powerlines/config";
|
|
95
|
+
import { plugin as openapi } from "@powerlines/plugin-openapi";
|
|
96
|
+
|
|
97
|
+
export default defineConfig({
|
|
98
|
+
plugins: [openapi({ schema: "./openapi.yml", outputPath: "src/generated" })],
|
|
99
|
+
openapi: { schema: "./openapi.yml", outputPath: "src/generated" }
|
|
100
|
+
});
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
Then run the Powerlines build for your project.
|
|
104
|
+
|
|
77
105
|
## Installing
|
|
78
106
|
|
|
79
107
|
Using [pnpm](http://pnpm.io):
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@powerlines/plugin-openapi",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.684",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A Powerlines plugin to generate project code from OpenAPI specifications.",
|
|
6
6
|
"repository": {
|
|
@@ -98,18 +98,18 @@
|
|
|
98
98
|
"@power-plant/core": "^0.0.98",
|
|
99
99
|
"@power-plant/openapi-schema": "^0.0.1",
|
|
100
100
|
"@power-plant/openapi-typescript": "^0.0.78",
|
|
101
|
-
"@powerlines/plugin-power-plant": "^0.1.
|
|
101
|
+
"@powerlines/plugin-power-plant": "^0.1.74",
|
|
102
102
|
"@stryke/fs": "^0.33.118",
|
|
103
103
|
"@stryke/path": "^0.29.43",
|
|
104
104
|
"defu": "^6.1.7",
|
|
105
|
-
"powerlines": "^0.47.
|
|
105
|
+
"powerlines": "^0.47.217",
|
|
106
106
|
"yaml": "^2.9.1"
|
|
107
107
|
},
|
|
108
108
|
"devDependencies": {
|
|
109
|
-
"@powerlines/plugin-plugin": "^0.12.
|
|
109
|
+
"@powerlines/plugin-plugin": "^0.12.630",
|
|
110
110
|
"@types/node": "^25.9.9"
|
|
111
111
|
},
|
|
112
112
|
"publishConfig": { "access": "public" },
|
|
113
113
|
"types": "./dist/index.d.cts",
|
|
114
|
-
"gitHead": "
|
|
114
|
+
"gitHead": "bb4e1f2b32a8bb9d20559ca7c3df3a2f30a0d14e"
|
|
115
115
|
}
|