为什么fa-heart-o不在fontawesome 5中工作?
我想在fontawesome 5免费版本中使用fa-heart-o
,但它不起作用。我应该怎么办?我可以在页面中使用2个版本的fontawesome吗? 4.7和5.1?因为它在4.7版本中工作。
这是我的代码:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<li>
<i class="fas fa-heart-o"></i>
</li>
<script src='https://kit.fontawesome.com/a076d05399.js' crossorigin='anonymous'></script>
</body>
</html>
I want to use fa-heart-o
in Fontawesome 5 free version but it is not working. what should I do? can I use 2 version of Fontawesome in a page? 4.7 and 5.1? because it is working in 4.7 version.
this is my code:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<li>
<i class="fas fa-heart-o"></i>
</li>
<script src='https://kit.fontawesome.com/a076d05399.js' crossorigin='anonymous'></script>
</body>
</html>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您需要更改为
&lt; i class =“ fas fa-heart-o”&gt;&lt;/i&gt;
&lt; i class =“ fas fa-heart”&gt;&lt ;/i&gt;
因为使用
-O
在Awesome Font 5中它无法正常工作。codepen
You need to change to
<i class="fas fa-heart-o"></i>
to<i class="fas fa-heart"></i>
because with the
-o
in awesome font 5 it wont work.Codepen