java swagger最新版本接入

参考:https://springdoc.org/

引入:

 <dependency>
      <groupId>org.springdoc</groupId>
      <artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
      <version>2.5.0</version>
   </dependency>

 

 
配置文件:
springdoc.api-docs.enabled=true
springdoc.api-docs.path=/api-docs
springdoc.swagger-ui.enabled=true
# swagger-ui custom path
springdoc.swagger-ui.path=/swagger-ui.html

 

posted @ 2024-04-12 21:02  然然1907  阅读(161)  评论(0编辑  收藏  举报