JSFiddle - React, Tailwind, and code Playground
by Boba Poshtar
HTML
<p>Тег <span>span</span> — універсальний строчний.</p>
<span class="icon"></span> 12 + 27 * 3 = <span id="res">?</span><br>
<button>Порахувати</button>
CSS
p span {
font-size: 200%;
text-transform: uppercase;
font-style: italic;
font-family: monospace;
}
.icon {
display: inline-block;
width: 400px;
height: 400px;
background: yellow url(https://upload-icon.s3.us-east-2.amazonaws.com/uploads/icons/png/8422811681584409092-64.png) no-repeat left top / cover;
}
JavaScript
document.querySelector('button').onclick = function (){
document.getElementById('res').innerText = 12 + 27 * 3;
};