CSS clamp() Text Size

clamp() creates responsive typography with min, preferred, and max values.

Preview

Code

<style>
h2{
font-size:clamp(20px, 5vw, 40px);
}
</style>

<h2>Responsive Heading</h2>

More CSS Math Functions Examples (8)