0.0.1 • Published 4 years ago
koa-route-schema-yapi v0.0.1
koa-route-schema-yapi
yapi export to koa-route-schema schemaOptions
Usage
import RouteSchema from 'koa-route-schema'
import yapiParseOptions from 'koa-route-schema-yapi'
import yapiSchemaOptions from './schemaOptions'
export default function attachSchema(router) {
let routeschema = RouteSchema({
...yapiParseOptions,
prefix: 'v1',
schemaOptions: yapiSchemaOptions
})
routeschema.attachToRouter(router)
}
0.0.1
4 years ago