2017-10-07 58 views
0

我使用的使用fontawesome下面的代码来表示登录和注册图标:fontawesome图标未在谷歌浏览器正确渲染

<a href="http://My-App-Local.dev/login"><i class="fa fa-sign-in fa-lg" aria-hidden="true"></i>&nbsp;Login</a> 

但如下呈现在Chrome浏览器:

enter image description here

然而,在Firefox相同的代码呈现象下面这样:

enter image description here

为什么在chrome中渲染不正确?

回答

0

显然字体没有在Chrome中加载。原因必须是包含链接到fontawesome.com的标头中的<script>标签 - 检查是否有任何拼写错误,缺少引号或类似内容。 (在特定情况下,Firefox可能更容忍打字错误/缺失字符)