JSFiddle - React, Tailwind, and code Playground
by Aminul Karim
HTML
<script src="http://jquery-textfill.github.com/jquery-textfill/jquery.textfill.min.js"></script>
<div class="container">
<h1 class=""><span>This is some text</span></h1>
</div>
<div class="container">
<h1 class="textfill"><span>This is some text</span></h1>
</div>
CSS
body{
}
.container{
background-color: #ff00ff;
width: 620px;
margin-bottom: 20px;
font-family: 'Helvetica', sans;
}
h1{
color: #fff;
text-transform:uppercase;
font-weight:bold;
font-size: 76px;
line-height: 1;
white-space: nowrap;
}
JavaScript
$(function(){
$('.textfill').textfill({ maxFontPixels: 176, widthOnly: true });
});