html - Font-Awesome 版本 6 图标未显示

第一个示例未显示,但第二个示例显示。为什么?

HTML

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.1/css/all.min.css" />
</head>
<body>
    <i class="fa-solid fa-square-info"></i> NOT SHOWING
    <i class="fas fa-info-circle"></i> SHOWING
</body>
</html>

最佳答案

这是因为 fa-solid fa-square-info 图标是一个 PRO 图标,它不能用于 font-awesome 的免费版本。所以图标没有渲染。或者你可以尝试使用 Material Design Icons它是开源的,可以免费使用。

https://stackoverflow.com/questions/71815963/

相关文章:

javascript - 为什么 react 会抛出 "Too many re-renders.",

html - 如何识别dex :get as being JSON or HTML in Commo

arrays - Matrix 有一列全部为 'true' 。如何在不到 O(mn) 的时间内找到它

c# - 如何在 EF Core 中插入外键影子属性?

c++ - 交换 const 成员是未定义的行为吗? C++17

next.js - Nextjs 试图找到一个不再存在的文件

json - 在 Rust 中使用可选的 JSON 字段,避免在 JSON 中使用 None/nul

c++ - 奇怪的 std::list 迭代行为

r - 通过匹配列和值 R 对数据帧进行子集和分组

vue.js - 如何使用 SSR 提高 Nuxt 的速度性能