编写配置类io.springfox >springfox-boot-starter3.0.0
@EnableWebMvc注解可以解决
Failed to start bean 'documentationPluginsBootstrapper’的问题
@Configuration
@EnableWebMvc
public class Swagger2Config {
}
注意:swagger2 3.0.0 之前的版本注解 @EnableWebMvc 改为 @EnableSwagger2
测试启动项目输入网址
Swagger2 2.x.x 版本网址为
http://localhost:8080/swagger-ui.html
Swagger2 3.0.0 之后的版本网址为
http://localhost:8080/swagger-ui/index.html



