Skip to content

Commit

Permalink
Adapt OpenAPI v3.1 specification.
Browse files Browse the repository at this point in the history
  • Loading branch information
samchon committed Apr 11, 2024
1 parent fbe753e commit f0e4c46
Show file tree
Hide file tree
Showing 186 changed files with 2,684 additions and 9,276 deletions.
2 changes: 1 addition & 1 deletion benchmark/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"homepage": "https://nestia.io",
"dependencies": {
"@nestia/core": "^2.6.3",
"typia": "^5.5.7"
"typia": "^6.0.0"
},
"devDependencies": {
"@types/autocannon": "^7.9.0",
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"private": true,
"name": "@nestia/station",
"version": "2.6.4",
"version": "3.0.0",
"description": "Nestia station",
"main": "prettier.config.js",
"scripts": {
Expand Down
11 changes: 6 additions & 5 deletions packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@nestia/core",
"version": "2.6.4",
"version": "3.0.0",
"description": "Super-fast validation decorators of NestJS",
"main": "lib/index.js",
"typings": "lib/index.d.ts",
Expand Down Expand Up @@ -36,24 +36,25 @@
},
"homepage": "https://nestia.io",
"dependencies": {
"@nestia/fetcher": "^2.6.4",
"@nestia/fetcher": "^3.0.0",
"@nestjs/common": ">=7.0.1",
"@nestjs/core": ">=7.0.1",
"@samchon/openapi": "^0.1.2",
"detect-ts-node": "^1.0.5",
"glob": "^7.2.0",
"multer": "1.4.5-lts.1",
"raw-body": "^2.0.0",
"reflect-metadata": ">=0.1.12",
"rxjs": ">=6.0.0",
"typia": "^5.5.7"
"typia": "^6.0.0"
},
"peerDependencies": {
"@nestia/fetcher": ">=2.6.4",
"@nestia/fetcher": ">=3.0.0",
"@nestjs/common": ">=7.0.1",
"@nestjs/core": ">=7.0.1",
"reflect-metadata": ">=0.1.12",
"rxjs": ">=6.0.0",
"typia": ">=5.5.7 <6.0.0"
"typia": ">=6.0.0 <7.0.0"
},
"devDependencies": {
"@fastify/multipart": "^8.1.0",
Expand Down
11 changes: 5 additions & 6 deletions packages/core/src/decorators/SwaggerCustomizer.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { ISwagger } from "../structures/ISwagger";
import { ISwaggerRoute } from "../structures/ISwaggerRoute";
import { OpenApi } from "@samchon/openapi";

/**
* Swagger customization decorator.
Expand Down Expand Up @@ -55,7 +54,7 @@ export namespace SwaggerCustomizer {
/**
* Swagger data.
*/
swagger: ISwagger;
swagger: OpenApi.IDocument;

/**
* Method of the route.
Expand All @@ -70,7 +69,7 @@ export namespace SwaggerCustomizer {
/**
* Route data.
*/
route: ISwaggerRoute;
route: OpenApi.IOperation;

/**
* Get neighbor endpoint data through the controller method.
Expand All @@ -86,7 +85,7 @@ export namespace SwaggerCustomizer {
* @param accessor Accessor for getting neighbor route data
* @returns Neighbor route data
*/
get(accessor: IAccessor): ISwaggerRoute | undefined;
get(accessor: IAccessor): OpenApi.IOperation | undefined;
}

/**
Expand All @@ -111,6 +110,6 @@ export namespace SwaggerCustomizer {
/**
* Route data.
*/
route: ISwaggerRoute;
route: OpenApi.IOperation;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export namespace TypedFormDataBodyProgrammer {
p.value.arrays.some((a) => isFile(a.type.value)),
)
.map((p) => ({
name: p.key.constants[0].values[0] as string,
name: p.key.constants[0].values[0].value as string,
limit: !!p.value.natives.length ? 1 : null,
}));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export namespace HttpQuerifyProgrammer {
),
...object.properties.map((p) =>
ts.factory.createExpressionStatement(
decode(p.key.constants[0]!.values[0] as string)(p.value),
decode(p.key.constants[0]!.values[0].value as string)(p.value),
),
),
ts.factory.createReturnStatement(
Expand Down
91 changes: 0 additions & 91 deletions packages/core/src/structures/ISwagger.ts

This file was deleted.

29 changes: 0 additions & 29 deletions packages/core/src/structures/ISwaggerComponents.ts

This file was deleted.

80 changes: 0 additions & 80 deletions packages/core/src/structures/ISwaggerInfo.ts

This file was deleted.

50 changes: 0 additions & 50 deletions packages/core/src/structures/ISwaggerRoute.ts

This file was deleted.

Loading

0 comments on commit f0e4c46

Please sign in to comment.