fond awesome官网: http://www.fontawesome.com.cn/
是一款基于css框架的网页字体图标库
今天在使用的时候发现下载文件后进行官网上的引入:
复制 font-awesome 目录到你的项目中
在处加载font-awesome.min.css如下:(自己替换路径)
<link rel="stylesheet" href="path/to/font-awesome/css/font-awesome.min.css">
选择要使用的图标,复制后添加到html中并不会显示图标
———————————————————————————
解决办法:
直接在 html 文档头部引用 CDN 文件就解决了问题,不需要下载到本地,然后在head头部引入。
<link rel="stylesheet" href="https://cdn.staticfile.org/font-awesome/4.7.0/css/font-awesome.css">
然后在fond awesome找到要使用的图标,复制后直接加入到html的中就好。