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

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

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

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation


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.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

              <p style="three quarters width with a black background, light text, red border, thick border, rounded, lots of padding, and a drop shadow">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Molestiae, tempore quam autem quod laudantium culpa illo, necessitatibus possimus neque eum rerum maiores alias quo laborum iste fugiat rem tenetur. Fugit.</p>
              @import "compass/css3";

// simple reset
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  line-height: 1.5;

// body breathing room
body {
  padding: 2em;

// syntax parsing

// width
[style*="full width"] { width: 100%; }
[style*="three quarters width"] { width: 75%; }
[style*="half width"] { width: 50%; }
[style*="quarter width"] { width: 25%; }

// background colors
[style*="gray background"] { background-color: #CCC; }
[style*="black background"] { background-color: #000; }
[style*="yellow background"] { background-color: #FF0; }
[style*="pink background"] { background-color: #FAA; }

// text colors
[style*="dark text"] { color: #000; }
[style*="light text"] { color: #FFF; }
[style*="red text"] { color: #F00; }

// add a border
[style*="border"] {
  border-width: 1px;
  border-style: solid;

// border colors
[style*="red border"] { border-color: #F00; }
[style*="black border"] { border-color: #000; }
[style*="green border"] { border-color: #0F0; }
[style*="blue border"] { border-color: #00F; }

// border thickness
[style*="thick border"] { border-width: 3px; }
[style*="really thick border"] { border-width: 8px; }

// border radius
[style*="rounded"] { border-radius: 5px; }

// padding
[style*="lots of padding"] { padding: 2em; }
[style*="normal padding"] { padding: 1em; }

// drop shadow
[style*="drop shadow"] { box-shadow: 0 1em 1em rgba(0,0,0,0.5); }
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.