漂亮的蓝色网站,学校网站群建设思路,十大创意网站,河北邯郸特产静态资源 一、静态资源二、首页和图标定制————————创作不易#xff0c;如觉不错#xff0c;随手点赞#xff0c;关注#xff0c;收藏(*#xffe3;︶#xffe3;)#xff0c;谢谢~~ 新依赖#xff1a;jquery的
dependencygroupIdorg.webjars如觉不错随手点赞关注收藏(*︶)谢谢~~ 新依赖jquery的
dependencygroupIdorg.webjars/groupIdartifactIdjquery/artifactIdversion3.4.1/version
/dependency一、静态资源
看一下源码 Override
public void addResourceHandlers(ResourceHandlerRegistry registry) {if (!this.resourceProperties.isAddMappings()) {// 已禁用默认资源处理logger.debug(Default resource handling disabled);return;}// 缓存控制Duration cachePeriod this.resourceProperties.getCache().getPeriod();CacheControl cacheControl this.resourceProperties.getCache().getCachecontrol().toHttpCacheControl();// webjars 配置if (!registry.hasMappingForPattern(/webjars/**)) {customizeResourceHandlerRegistration(registry.addResourceHandler(/webjars/**).addResourceLocations(classpath:/META-INF/resources/webjars/).setCachePeriod(getSeconds(cachePeriod)).setCacheControl(cacheControl));}// 静态资源配置String staticPathPattern this.mvcProperties.getStaticPathPattern();if (!registry.hasMappingForPattern(staticPathPattern)) {customizeResourceHandlerRegistration(registry.addResourceHandler(staticPathPattern).addResourceLocations(getResourceLocations(this.resourceProperties.getStaticLocations())).setCachePeriod(getSeconds(cachePeriod)).setCacheControl(cacheControl));}
}优先级 我们也可以设置让它失效 失效 二、首页和图标定制
1、首页可以放到这三个文件夹里面会覆盖 2、图标定制 图标变了 ————————
创作不易如觉不错随手点赞关注收藏(*︶)谢谢~~