Hi, its really nice article. Btw, do you have any tricks to use responsive font size without media query ? I usually use media query to resize the font, but the font size is not scaling in the larger device screen, its size just fixed based on i defined in media query
A London Web Developer. A lot of my professional experience is in digital agencies and I enjoy helping new front-end developers learn how to code websites.
This will scale your font with the width of the screen. Of course, the caveat being that on a TV or abnormally ultra wide screen, you'll have issues with text being huge. So you'll need to use media queries to tame it.
Thanks!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi, its really nice article. Btw, do you have any tricks to use responsive font size without media query ? I usually use media query to resize the font, but the font size is not scaling in the larger device screen, its size just fixed based on i defined in media query
You can use calc combined with media queries.
font-size: calc(16px + 0.5vw);
This will scale your font with the width of the screen. Of course, the caveat being that on a TV or abnormally ultra wide screen, you'll have issues with text being huge. So you'll need to use media queries to tame it.
Thanks!