Skip to content

Commit d2f044c

Browse files
authored
I make the ng folder serve as static content in Spring boot to support Angular apps (#1023)
Issue: 206593
1 parent f7934d2 commit d2f044c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

gxspringboot/src/main/java/com/genexus/springboot/GXConfig.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,9 @@ public void addResourceHandlers(ResourceHandlerRegistry registry) {
4646
registry.addResourceHandler(webImageDir + "**")
4747
.addResourceLocations("classpath:" + webImageDir);
4848

49+
registry.addResourceHandler("/_ng/**")
50+
.addResourceLocations("classpath:/ng/");
51+
4952
registry.addResourceHandler("/" + blobPath + "/**")
5053
.addResourceLocations("file:./" + blobPath + "/");
5154
}
@@ -71,6 +74,7 @@ public FilterRegistrationBean<UrlRewriteFilter> urlRewriteFilter() {
7174
if (new ClassPathResource(REWRITE_FILE).exists()) {
7275
registrationBean.addInitParameter("modRewriteConf", "true");
7376
registrationBean.addInitParameter("confPath", REWRITE_FILE);
77+
registrationBean.setOrder(org.springframework.core.Ordered.HIGHEST_PRECEDENCE);
7478
}
7579
else {
7680
registrationBean.setEnabled(false);

0 commit comments

Comments
 (0)