@tahminator/sapling 1.5.5 → 1.5.7
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 +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -184,11 +184,11 @@ Sapling.loadResponseStatusErrorMiddleware(app, (err, req, res, next) => {
|
|
|
184
184
|
Load Express middleware plugins using `@Middleware()`:
|
|
185
185
|
|
|
186
186
|
```typescript
|
|
187
|
-
import {
|
|
187
|
+
import { MiddlewareClass, Middleware } from "@tahminator/sapling";
|
|
188
188
|
import cookieParser from "cookie-parser";
|
|
189
189
|
import { NextFunction, Request, Response } from "express";
|
|
190
190
|
|
|
191
|
-
@MiddlewareClass() //
|
|
191
|
+
@MiddlewareClass() // @MiddlewareClass is an alias of @Controller, provides better semantics
|
|
192
192
|
class CookieParserMiddleware {
|
|
193
193
|
private readonly plugin: ReturnType<typeof cookieParser>;
|
|
194
194
|
|