Font Awesomeをcssで使う時に表示されない件
Font Awesomeのアイコンをcssの疑似要素で以下のように使うと、私の環境だと□になってしまう。
CDN(htmlのhead部分で読み込ませる)
<link href="https://use.fontawesome.com/releases/v5.0.6/css/all.css" rel="stylesheet">
.hoge::before { font-family: "Font Awesome 5 Free"; content: "\f015"; }
調べたら、一部のフォントのみcssで
font-weight: bold;
とか
font-weight: 900;
とかを指定しないと表示されないとの事で追加したら表示されました。
.hoge::before { font-family: "Font Awesome 5 Free"; content: "\f015"; font-weight: bold; }
どうでもいいのですが数字指定の場合、501以上の数値を入力しないと表示されない様子(全て試した訳ではないです)。