JSFiddle - React, Tailwind, and code Playground

by CallMeLaNN

HTML

<p>This sample is to test setting jQuery .html('&amp;nbsp;') and .text(' ') into a table cell and effect to the border line on Print Preview.</p>
<p>You can see all the border line for the three cells but try to see on the Print Preview for missing border line.</p>
<p>Click on empty space on non-editor and result area of jsFiddle if you cannot see anything in the preview.</p>
<br />
<table class="tSample" border="0" cellspacing="0" cellpadding="0">
    <tr>
        <td>&nbsp;</td>
        <td>Sample cell</td>
        <td>&nbsp;</td>
        <td>.html('&amp;nbsp;')</td>
        <td>&nbsp;</td>
        <td>.text(' ')</td>
        <td>&nbsp;</td>
    </tr>
    <tr>
        <td>&nbsp;</td>
        <td class="sample" style="border: 1px solid #000;">&nbsp;</td>
        <td>&nbsp;</td>
        <td class="testHtml">&nbsp;</td>
        <td>&nbsp;</td>
        <td class="testText"></td>
        <td>&nbsp;</td>
    </tr>
    <tr>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
    </tr>
</table>
<script type="text/javascript" src="https://getfirebug.com/firebug-lite.js"></script>

CSS

table
{
    border-collapse: separate; /* Remove normalize style from JsFiddle, separate is default in IE7 */
}
.tSample, .sample, .testHtml, .testText
{
    border: 1px solid #000;
    background-color: transparent;
}
.tSample tr
{
    height: 30px;
}
.sample, .testHtml, .testText
{
    width: 100px;
}

JavaScript

$(document).ready(function() {
    $('.testHtml').html('&nbsp;');
    $('.testText').text(' ');
});