只需要建一个fonts文件夹放在和js,css文件同级目录下,就可以正确引用。
关键是下面这几个文件得有:
glyphicons-halflings-regular.eotglyphicons-halflings-regular.svgglyphicons-halflings-regular.ttfglyphicons-halflings-regular.woff
相关的 CSS 规则写在 dist 文件夹内的 css 文件夹内的 bootstrap.css 和 bootstrap-min.css 文件上。
字体文件的路径请灵活改变
所以 font-face 规则实际上是在找到 glyphicons 地方声明 font-family 和位置。