JSFiddle - React, Tailwind, and code Playground
by web5me
HTML
<div class="link-thumb" id="id">
<a href="#">
<img class="thumb" id="id" src="http://placekitten.com/100/100" alt="foo" width="100" height="100" />
<span class="desc">Frosted Flower Choker Necklace 18"</span>
</a>
</div>
CSS
.link-thumb { position:relative; float: left; border: 1px solid gold; }
.link-thumb img { display: block; }
.desc { position: absolute; padding-top: 5px; }
JavaScript
$('.thumb').on('load', function() {
var $this = $(this);
//$this.closest('.link-thumb').width( $this.width() );
});