Skip to content

Commit db9dc60

Browse files
fix : snippets loading error on spring-rest-doc (manual)
1 parent db6fda9 commit db9dc60

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
#### Import the SQL file in the ``mysql`` folder.
2424

25-
#### The API information is on ``src/main/asciidoc/api-app.adoc``, managed by Spring Rest Doc.
25+
#### The API information is found on ``http://localhost:8505/docs/api-app.html``, managed by Spring Rest Doc
2626

2727

2828

pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ http://maven.apache.org/xsd/maven-4.0.0.xsd">
218218
<plugin>
219219
<groupId>org.asciidoctor</groupId>
220220
<artifactId>asciidoctor-maven-plugin</artifactId>
221-
<version>1.5.8</version>
221+
<version>2.2.6</version>
222222
<executions>
223223
<execution>
224224
<id>generate-docs</id>
File renamed without changes.

src/main/java/com/patternknife/securityhelper/oauth2/config/security/web/WebMvcConfig.java

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,7 @@
44
import lombok.RequiredArgsConstructor;
55
import org.springframework.context.annotation.Configuration;
66
import org.springframework.http.HttpMethod;
7-
import org.springframework.web.servlet.config.annotation.CorsRegistry;
8-
import org.springframework.web.servlet.config.annotation.EnableWebMvc;
9-
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
10-
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
7+
import org.springframework.web.servlet.config.annotation.*;
118

129
@RequiredArgsConstructor
1310
@Configuration
@@ -28,6 +25,11 @@ public void addCorsMappings(CorsRegistry registry) {
2825
HttpMethod.DELETE.name());
2926
}
3027

28+
@Override
29+
public void addResourceHandlers(ResourceHandlerRegistry registry) {
30+
registry.addResourceHandler("/docs/**").addResourceLocations("classpath:/static/docs/");
31+
}
32+
3133

3234

3335
@Override

0 commit comments

Comments
 (0)