JSFiddle - React, Tailwind, and code Playground

HTML

<table>
    <thead>
        <tr>
            <th>Column 1: Dummy to make right hand column visible</th>
            <th>Column 2</th>
        </tr>
    </thead>
    <tbody>
        <tr>
            <td>Dummy</td>
            <td id="cell1">cell1</td>
        </tr>
        <tr>
            <td>Dummy</td>
            <td id="cell2">cell2</td>
        </tr>
        <tr>
            <td>Dummy</td>
            <td id="cell3">cell3</td>
        </tr>
</table>

CSS

th,td {border: 1px solid black;}

JavaScript

function SF(msg) { // success or failure for callback
    alert(msg);
}

function s1() {
    $('#cell1').html('1');
}

function s2() {
    $('#cell2').html('2');
}

function s3() {
    $('#cell3').html('3');
}

// synchronous example of $.when().then()
$.when(s1(), s3()).then(function () {
    SF('success');
}, function () {
    SF('failure');
});
s2();