静态资源外部配置
@Configuration
public class MyWebAppConfigurer
extends WebMvcConfigurerAdapter {
@Override
public void addResourceHandlers(ResourceHandlerRegistry registry) {
registry.addResourceHandler("/wiki/**").addResourceLocations("file:C:/Users/XiaoBai/Desktop/wiki/");
super.addResourceHandlers(registry);
}
}