add dark theme to swagger docs

This commit is contained in:
2023-07-21 23:43:21 +02:00
parent 8e374fbaa4
commit c593ccea05
8 changed files with 2462 additions and 3 deletions

View File

@@ -28,7 +28,10 @@ async function bootstrap() {
.build()
const document = SwaggerModule.createDocument(app, config)
SwaggerModule.setup('docs', app, document)
SwaggerModule.setup('docs', app, document, {
customJs: '/swagger-ui.js',
customCssUrl: '/swagger-themes/dark.css',
})
pipesSetup(app)
app.useGlobalFilters(new HttpExceptionFilter())
await app.listen(process.env.PORT || 3000)
@@ -38,7 +41,7 @@ async function bootstrap() {
}
try {
bootstrap()
void bootstrap()
} catch (e) {
console.log('BOOTSTRAP CALL FAILED')
console.log('ERROR: ')