swagger文档和 knife4j 文档
老版本的swagger-bootstrap-ui,可以显示非RestController,可以测试html页面显示,可以和springfox-swagger-ui配合显示
<!--swagger --> <dependency> <groupId>io.springfox</groupId> <artifactId>springfox-swagger2</artifactId> <version>2.9.2</version> </dependency> <!--swagger-ui.html模式 --> <dependency> <groupId>io.springfox</groupId> <artifactId>springfox-swagger-ui</artifactId> <version>2.9.2</version> </dependency> <!--doc.html模式 --> <dependency> <groupId>com.github.xiaoymin</groupId> <artifactId>swagger-bootstrap-ui</artifactId> <version>1.9.6</version> </dependency>
新版本的knife4j文档,只能显示RestController(不知是否配置问题),用了后springfox-swagger-ui不能显示,用了之后Controller显示英文,不显示Api注解配置的中文,原因暂不清楚
<dependency> <groupId>org.springdoc</groupId> <artifactId>springdoc-openapi-ui</artifactId> <!--版本需和knife4j-openapi3-spring-boot-starter中依赖的版本相同--> <version>1.6.9</version> </dependency> <dependency> <groupId>com.github.xiaoymin</groupId> <artifactId>knife4j-openapi3-spring-boot-starter</artifactId> <version>4.0.0</version> </dependency>