Skip to content

Commit edf2f2d

Browse files
author
DylanBulmer
committed
allow multiple express middlewares in one request
1 parent 85e734b commit edf2f2d

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
22
"name": "@dylanbulmer/openapi",
3-
"version": "1.0.3",
3+
"version": "1.0.4",
44
"main": "index.js",
55
"author": "Dylan Bulmer <dylan@bulmersolutions.com>",
66
"license": "MIT",
77
"scripts": {
8-
"test": "jest --config jestconfig.json --passWithNoTests",
8+
"test": "jest --config jestconfig.json --passWithNoTests --coverage",
99
"build": "yarn clean && tsc && cp package.json lib/",
1010
"clean": "rm -rf ./lib",
1111
"format": "prettier --write \"src/**/*.(ts|js)\"",

src/types/Route.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export enum Method {
2020
"HEAD" = "head",
2121
}
2222

23-
export type Operation = RequestHandler & {
23+
export type Operation = (RequestHandler | RequestHandler[]) & {
2424
apiDoc?: OpenAPIV3_1.OperationObject;
2525
};
2626

src/utils/elements-ui.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export const render = function render(apiDocs: OpenAPIV3_1.Document) {
66
<head>
77
<meta charset="utf-8">
88
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
9-
<title>${apiDocs.info.title} Docs</title>
9+
<title>${apiDocs.info.title}</title>
1010
1111
<script src="https://unpkg.com/@stoplight/elements/web-components.min.js"></script>
1212
<link rel="stylesheet" href="https://unpkg.com/@stoplight/elements/styles.min.css">

0 commit comments

Comments
 (0)