🎉 feat: user provided components

This commit is contained in:
saltyaom
2023-08-17 15:40:07 +07:00
4 changed files with 61 additions and 47 deletions

View File

@@ -10,18 +10,31 @@ const app = new Elysia({
documentation: {
info: {
title: 'Elysia',
version: '0.5.0'
version: '0.6.10'
},
tags: [
{
name: 'Test',
description: 'Hello'
}
]
],
components: {
schemas: {
User: {
description: 'string'
}
},
securitySchemes: {
JwtAuth: {
type: 'http',
scheme: 'bearer',
bearerFormat: 'JWT',
description: 'Enter JWT Bearer token **_only_**'
}
}
}
}
})
)
.use(plugin)
.listen(8080)
console.log(app.routes)