@alevnyacow/nzmt 0.27.4 → 0.27.5
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 +8 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -217,6 +217,14 @@ foo = this.methods('foo', async ({ str }) => {
|
|
|
217
217
|
// ..service class implementation
|
|
218
218
|
```
|
|
219
219
|
|
|
220
|
+
### Usage
|
|
221
|
+
|
|
222
|
+
Service methods can be used like a usual method of signature `(data: Request) => Promise<Response>`. E.g.
|
|
223
|
+
|
|
224
|
+
```ts
|
|
225
|
+
const { num } = await someMethod.foo({ str: '25' })
|
|
226
|
+
```
|
|
227
|
+
|
|
220
228
|
## Controllers
|
|
221
229
|
|
|
222
230
|
Same idea, but metadata uses optional `query`, optional `body`, and `response`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alevnyacow/nzmt",
|
|
3
|
-
"version": "0.27.
|
|
3
|
+
"version": "0.27.5",
|
|
4
4
|
"description": "Next Zod Modules Toolkit",
|
|
5
5
|
"keywords": ["next", "full-stack", "server", "backend", "cli", "scaffolding", "zod", "rest", "contract programming", "contract-first", "react-query", "ddd", "domain-driven"],
|
|
6
6
|
"repository": {
|