JSFiddle - React, Tailwind, and code Playground

HTML

<div class='row'>

  <div class='cell'> 
    <span class='image'> </span>
    Image Cell
  </div>

  <div class='cell'>
     Regular Cell
  </div>

</div>

JavaScript

Array.prototype.forEach.call(document.querySelectorAll(".cell"), function (el) {
        if (el.querySelector("span")) {
            el.style.color = "red";
        }
    });