JSFiddle - React, Tailwind, and code Playground

HTML

<div>
     <img src="http://www.placeghfghfdghhold.it/100x100?RenditionID=7" />
    </div>
    
   
<div class="nbbox" data-title="An update from the External Affairs team">
        <img src="https://cc.sharepoint.com/sites/connect/globalnews/PublishingImages/Leadership%20team/Tim-Boardley.jpg?RenditionID=7" alt="An update from the External Affairs team">
        <a href="/sites/connect/globalnews/Pages/An-update-from-the-External-Affairs-team.aspx" data-title="An update from the External Affairs team">
            <div class="nboverlay">
                <div class="nbtitle">
                    <span>An update from the External Affairs team</span>
                </div>
                <p class="nbheadline">
                    </p><p>​A message from Tom Boardley</p>
                <p></p>
                <p class="nbdate">
                14 August 2018
                </p>
            </div>
        </a>
    </div>


    <img src="http://www.placgdhdhehold.it/100x100?RenditionID=7" />



    <img src="http://www.placehold.it/100x100?RenditionID=7" />

JavaScript

// I want to be able to figure out a way with jQuery, to take the value of 'P' from the parent link (100, 660, 32) and then change the image src from "placehold.it" to "/100.jpg" if at all possible?

$('.nbbox > img').each ( function (index) {
    var link_href = $(this).attr('src');

    var ren = link_href.slice(-1); //gets rendition number
    //alert(ren); 
   
 
   if (ren == '7'){
   img_src = link_href.substring(0,link_href.length-1) + '3';
   // alert(img_src)
   this.src = img_src ;
   }
});