Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                    <table>
    <caption>A summary of the UK's most famous punk bands</caption>
    <thead>
        <tr>
        <th scope="col">Band</th>
        <th scope="col">Year formed</th>
        <th scope="col">No. of Albums</th>
        <th scope="col">Most famous song</th>
        </tr>
    </thead>
    <tbody>
        <tr>
        <th scope="row">Buzzcocks</th>
        <td>1976</td>
        <td>9</td>
        <td>Ever fallen in love (with someone you shouldn't've)</td>
        </tr>
        <tr>
        <th scope="row">The Clash</th>
        <td>1976</td>
        <td>6</td>
        <td>London Calling</td>
        </tr>
        <tr>
        <th scope="row">The Damned</th>
        <td>1976</td>
        <td>10</td>
        <td>Smash it up</td>
        </tr>
        <tr>
        <th scope="row">Sex Pistols</th>
        <td>1975</td>
        <td>1</td>
        <td>Anarchy in the UK</td>
        </tr>
        <tr>
        <th scope="row">Sham 69</th>
        <td>1976</td>
        <td>13</td>
        <td>If the kids are united</td>
        </tr>
        <tr>
        <th scope="row">Siouxsie and the Banshees</th>
        <td>1976</td>
        <td>11</td>
        <td>Hong Kong Garden</td>
        </tr>
        <tr>
        <th scope="row">Stiff Little Fingers</th>
        <td>1977</td>
        <td>10</td>
        <td>Suspect Device</td>
        </tr>
        <tr>
        <th scope="row">The Stranglers</th>
        <td>1974</td>
        <td>17</td>
        <td>No More Heroes</td>
        </tr>
    </tbody>
    <tfoot>
        <tr>
        <th scope="row" colspan="2">Total albums</th>
        <td colspan="2">77</td>
        </tr>
    </tfoot>
    </table>

              
            
!

CSS

              
                
    
table {
  color: #333;
  font: 1.2em / 1.5 Helvetica Neue, Helvetica, Arial, sans-serif;
  font-size: 75%;
  table-layout: fixed;
  border-top: 2px solid rgb(197, 197, 197);
  border-bottom: 1px solid rgb(197, 197, 197);
  border-collapse: collapse;
}

tbody th, tbody td:nth-child(4) {
  text-align: left;
}


thead th:nth-child(1), thead th:nth-child(4) {
  text-align: left;
}


thead th:nth-child(2), thead th:nth-child(3) {
  text-align: right;
}



tbody td:nth-child(2), tbody td:nth-child(3) {
  text-align: right;
}

tbody tr:nth-child(odd) {
  background-color: rgb(238, 238, 238);
}

tfoot th {
  text-align: right;
}

td, th {
  padding: 5px;
  vertical-align: top;
}

tfoot {
  border-top: 1px solid rgb(197, 197, 197);
}
              
            
!

JS

              
                
              
            
!
999px

Console