@webnode-plugin/ssot
v1.0.10
Published
Swagger Cli
Readme
SSOT
Swagger Cli
Goal
- TypeScript controllers and models as the single source of truth for your API
- A valid swagger spec is generated from your controllers and models, including:
- Paths (e.g. GET /Users)
- Definitions based on TypeScript interfaces (models)
- Parameters/model properties marked as required or optional based on TypeScript (e.g. myProperty?: string is optional in the Swagger spec)
- jsDoc supported for object descriptions (most other metadata can be inferred from TypeScript types)
- Validate request payloads
Annotations
https://github.com/lukeautry/tsoa/blob/121565d0facbe86d1793612cab0a8df666e5d6f9/tests/fixtures/testModel.ts
ROADMAP
- [ ] pont支持
- [ ] Annotations支持
- [ ] 添加单元测试
参考材料
- https://github.com/lukeautry/tsoa
- https://github.com/YousefED/typescript-json-schema
- https://github.com/microsoft/TypeScript/wiki/Using-the-Compiler-API
