Fit text perfectly inside a div (height and width) without affecting the size of the div

前端 未结 9 1850
盖世英雄少女心
盖世英雄少女心 2020-12-02 17:07

I apologise in advance as I know this question has come up many times before but I just can\'t seem to find the right solution (and believe me I\'ve tried a few!)

Ba

9条回答
  •  甜味超标
    2020-12-02 18:08

    I got the same problem and the solution is basically use javascript to control font-size. Check this example on codepen:

    https://codepen.io/ThePostModernPlatonic/pen/BZKzVR
    

    try to resize it

    
    
    
    
    Documento sem título
    
    
    
    

    Because too much "light" doesn't illuminate our paths and warm us, it only blinds and burns us.

提交回复
热议问题