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

              
                <article>
  <h2>Article Title</h2>
  <time>January 8, 1029</time>
  <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Ullam veniam dicta tempore nisi molestias, expedita iusto quam aut odit eligendi sint perspiciatis aliquid sapiente similique totam, voluptate facere dolorem atque!</p>
</article>
<article>
  <h2>Article Lorem Ipsum Dolor Sit Amet</h2>
  <time>February 27, 2019</time>
  <p>Lorem ipsum dolor, sit amet consectetur adipisicing elit. Atque eos id aliquid maiores voluptatibus iure velit sapiente tenetur quae assumenda dignissimos cumque delectus, consequuntur dolorum numquam qui suscipit nemo amet!</p>
</article>
<article>
  <h2>Suscipit Iusto Aut Distinctio</h2>
  <time>March 30, 2019</time>
  <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Suscipit iusto aut distinctio doloribus corrupti maxime. Debitis similique cum ab quas cupiditate ex, rem perspiciatis eveniet cumque, accusamus delectus unde animi?</p>
</article>
<article>
  <h2>Sit Vitae Magnam Architecto</h2>
  <time>April 17, 2019</time>
  <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consequatur voluptatibus asperiores libero tempora. Minus aperiam recusandae beatae ad neque eveniet esse numquam, quisquam assumenda, sit vitae magnam architecto deserunt placeat!</p>
</article>
<article>
  <h2>Article Nobis Pariatur</h2>
  <time>May 7, 2019</time>
  <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Accusamus facilis voluptatibus quidem, id accusantium libero iste inventore molestias veniam, consequuntur nobis pariatur doloribus qui nam aspernatur culpa? Hic, repellat eius?</p>
</article>
              
            
!

CSS

              
                body {
  display: grid;
  grid-template-columns: 
    [meta-start] max-content 
    [meta-end main-start] minmax(min-content, 70ch)
    [main-end]
  ;
  justify-content: center;
  grid-gap: 1em;
  padding: 2em 1em;
}

article {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: subgrid;
  grid-auto-flow: row dense;
}

time {
  align-self: center;
  grid-column: meta;
  text-align: right;
  background: lightgray;
}

h2, p {
  grid-column: main;
  margin: 0;
}
              
            
!

JS

              
                
              
            
!
999px

Console