springboot定义swagger2的UI界面

在pom.xml中配置依赖,以本地localhost:8080访问为例
1、访问http://localhost:8080/swagger-ui.html

<dependency>
    <groupId>io.springfox</groupId>
    <artifactId>springfox-swagger-ui</artifactId>
    <version>2.10.5</version>
</dependency>

2、访问http://localhost:8080/doc.html

<dependency>
    <groupId>com.github.xiaoymin</groupId>
    <artifactId>swagger-bootstrap-ui</artifactId>
    <version>1.9.3</version>
</dependency>

3、访问http://localhost:8080/docs.html

<dependency>
    <groupId>com.github.caspar-chen</groupId>
    <artifactId>swagger-ui-layer</artifactId>
    <version>1.1.3</version>
</dependency>

4、访问http://localhost:8080/document.html

<dependency>
    <groupId>com.zyplayer</groupId>
    <artifactId>swagger-mg-ui</artifactId>
    <version>2.0.1</version>
</dependency>
上一篇:域名服务器 DNS


下一篇:Centos7主机名变成bogon的原因及解决方法