云端漂移 2020-02-24
解决方法:build中加过滤存在多级目录要把目录多级处理定位:
<resources> <resource> <directory>src/main/resources</directory> <filtering>true</filtering> <excludes> <exclude>static/Bootstrap/bootstrap/layui/font/*</exclude> <exclude>static/Bootstrap/bootstrap/layui/css/**</exclude> <exclude>static/Bootstrap/bootstrap/**</exclude> <exclude>**/*.xml</exclude> <exclude>**/*.setting</exclude> <exclude>**/*.json</exclude> <exclude>**/*.properties</exclude> <exclude>**/*.html</exclude> <exclude>**/*.map</exclude> <exclude>**/*.css</exclude> <exclude>**/*.gif</exclude> <exclude>**/*.png</exclude> <exclude>**/*.js</exclude> <exclude>**/*.eot</exclude> <exclude>**/*.svg</exclude> <exclude>**/*.ttf</exclude> <exclude>**/*.woff</exclude> <exclude>**/*.woff2</exclude> </excludes> </resource> <resource> <directory>src/main/resources</directory> <filtering>false</filtering> <includes> <include>static/Bootstrap/bootstrap/layui/font/*</include> <include>static/Bootstrap/bootstrap/layui/css/**</include> <include>static/Bootstrap/bootstrap/**</include> <include>**/*.xml</include> <include>**/*.setting</include> <include>**/*.json</include> <include>**/*.properties</include> <include>**/*.html</include> <include>**/*.map</include> <include>**/*.css</include> <include>**/*.gif</include> <include>**/*.png</include> <include>**/*.js</include> <include>**/*.eot</include> <include>**/*.svg</include> <include>**/*.ttf</include> <include>**/*.woff</include> <include>**/*.woff2</include> </includes> </resource> </resources>
使用 CSS3,网页设计师可以使用他/她喜欢的任何字体。只需简单的将字体文件包含在网站中,它会自动下载给需要的用户。在新的 @font-face 规则中,您必须首先定义字体的名称,然后指向该字体文件。