Chrome not respecting rem font size on body tag?

前端 未结 7 885
北恋
北恋 2020-12-08 22:37

I\'ve taken to using rem\'s to size fonts in recent projects, then using px as a fallback for older versions of IE.

I\'ve also been setting a font

7条回答
  •  爱一瞬间的悲伤
    2020-12-08 23:04

    The * selector is very slow, as the author of this bug in Chrome, I'd advise a workaround like this until the bug is fixed:

    body > div {
        font-size: 1.4rem;
    }
    

    Provided you always have a wrapper div anyway ;)

提交回复
热议问题