diff --git a/pom.xml b/pom.xml index 44c3e15..5f9caf0 100644 --- a/pom.xml +++ b/pom.xml @@ -22,6 +22,8 @@ 3.5.12 2.3.34 + + 2.8.9 @@ -86,6 +88,13 @@ + + + org.springdoc + springdoc-openapi-starter-webmvc-ui + ${webmvc-ui.version} + + org.projectlombok diff --git a/src/main/resources/application-dev.yml b/src/main/resources/application-dev.yml index 7743742..73ca6a8 100644 --- a/src/main/resources/application-dev.yml +++ b/src/main/resources/application-dev.yml @@ -4,4 +4,16 @@ spring: datasource: url: jdbc:mysql://localhost:3306/personal_blog?autoReconnect=true&characterEncoding=utf8 username: root -# password: password, # 密码不建议写在配置文件中, 建议利用Idea中的配置覆盖, 如果是其他IDE请自行斟酌 \ No newline at end of file +# password: password, # 密码不建议写在配置文件中, 建议利用Idea中的配置覆盖, 如果是其他IDE请自行斟酌 +# 接口文档生成相关配置 +springdoc: + swagger-ui: + path: /api.html + tags-sorter: alpha + operations-sorter: alpha + # 是否启用swagger-ui + enabled: true + api-docs: + path: /v1/api-docs + # 是否启用api文档模板, 关闭后无法使用快速导入api文档 + enabled: true \ No newline at end of file