Font awesome icon showing as square in chrome?

后端 未结 6 1195
生来不讨喜
生来不讨喜 2021-02-20 03:49

I am trying to use a font-awsome icon within a button. The icon works fine in firefox but when I use it in chrome it appears as a square. I have looked around and the only thing

6条回答
  •  一整个雨季
    2021-02-20 04:25

    Very late answer but this might help another brother out there!

    I found out that this behaviour was solved by NOT having display: block; on the i/.fa element.

    .fa is standard inline-block but I changed it to block for better compatibility for old browsers, but it has to be inline-block or maybe something else similar.

    Hope it helps someone out there!

提交回复
热议问题