Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ 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

Auto Save

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

              
                <div class="container">
  <section>
    <h4>The following paragraph can be highlighted.</h4>
    <p title="Try highlighting me!">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis dolor risus, semper nec velit et, aliquam rhoncus nisl. Integer justo magna, efficitur a lacus a, rutrum dapibus odio. Vestibulum interdum diam vitae sagittis tincidunt. Aliquam ligula mi, cursus et gravida nec, facilisis eget lectus. Suspendisse et nulla a dui ultrices condimentum id pellentesque elit. Aliquam vitae commodo mauris. Mauris fermentum volutpat ligula sit amet tincidunt. Phasellus venenatis nulla sed est convallis euismod. Sed a velit id nisl varius condimentum ut sed nibh.</p>
  </section>
  <section>
    <h4>The following paragraph cannot be highlighted.</h4>
    <p class="no-highlight" title="Try highlighting me!">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse at nisl efficitur nisi venenatis sagittis sit amet ut nisl. Duis faucibus vel quam ut scelerisque. Nunc tellus felis, pellentesque a urna et, condimentum consectetur velit. Proin vel metus vel mi cursus viverra vitae eget dui. Donec imperdiet convallis massa nec congue. Sed facilisis libero in tincidunt efficitur. Donec eu lacus aliquet, rutrum nibh a, viverra lorem. Sed tellus purus, scelerisque at felis ut, sodales facilisis eros. Quisque dapibus felis vel velit pretium placerat.</p>
  </section>
</div>
              
            
!

CSS

              
                body {
  height: 100vh;
  display: grid;
  place-items: center;
  font-family: Arial, sans-serif;
}

.container {
  width: calc(100% - 9rem);
}

.no-highlight {
  -webkit-user-select: none;
  -moz-user-select: none;
  user-select: none;
}
              
            
!

JS

              
                
              
            
!
999px

Console