修复Network中所有前端路由资源请求均报404错误 #1982 (#1985)

This commit is contained in:
yxm-coding
2024-12-27 20:54:53 +08:00
committed by GitHub
parent 3e1e5ae209
commit 683f01c33b

View File

@@ -19,5 +19,6 @@ public class WebConfig implements WebMvcConfigurer {
public void addViewControllers(ViewControllerRegistry registry) {
registry.addViewController("/").setViewName("redirect:/webapp/");
registry.addViewController("/webapp/").setViewName("forward:/webapp/index.html");
registry.addViewController("/webapp/**/{path:[^\\.]*}").setViewName("forward:/webapp/index.html");
}
}