Pen Settings



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


Babel is required to process package imports. If you need a different preprocessor remove all packages first.

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


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.


                <p>Create a slider by adding the class <code>.slider</code> and the attribute <code>data-slider</code> to a container element. You should also define both a starting and maximum value for the slider.</p>

<p>Inside the container are three elements:</p>

  <li>The handle (<code>.slider-handle</code>), which the user drags.</li>
  <li>The fill (<code>.slider-fill</code>), which resizes dynamically based on where the handle is.</li>
  <li>A hidden <code>&lt;input&gt;</code>, which is where the value of the slider is stored.</li>

<p>The <code>data-initial-start=""</code> value is where along the slider the handle starts. The <code>data-end=""</code> is the maximum value for the slider. In the below example, starting at 50 of 200 means the slider handle will start at 25% of the total.</p>

<p>Add the <code>.vertical</code> class and the <code>data-vertical="true"</code> attribute to the slider to make it vertical.</p>

<div class="slider vertical" data-slider data-initial-start="25" data-end="200" data-vertical="true">
  <span class="slider-handle" data-slider-handle role="slider" tabindex="1"></span>
  <span class="slider-fill" data-slider-fill></span>
  <input type="hidden">


                body {
  margin: 2rem;