JSFiddle - React, Tailwind, and code Playground

HTML

<div class="box"><div class="corner">
  <span href="#">Best Ribbon around</span>
    
    
</div>
<img src="http://lorempixel.com/250/300/sports/1/">
</div>

CSS

body {background:yellow;padding:50px}

.box {
    position:relative;
    padding:3%; 
    width:260px; 
    background:#ccc; 
    overflow:hidden;
    -moz-box-shadow: 0 0 0 2px green inset;
    -webkit-box-shadow: 0 0 0 2px green inset;
    box-shadow: 0 0 0 2px green inset;
}

.corner {
    background-color: #a00;
    overflow: hidden;
    position: absolute;
    left: -3em;
    top: 2.5em;
    -moz-transform: rotate(-45deg);
    -webkit-transform: rotate(-45deg);
    transform: rotate(-45deg);

}
.corner span {
    border: 1px solid #faa;
    color: #fff;
    display: block;
    font-size:.8em;
    font-weight:bold;
    padding: 0.5em 4em;
    text-align: center;
    text-decoration: none;
    text-shadow: 1px 1px 1px #000;
}