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. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ 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

              
                <main class="container">
	<nav class="element-nav">
		<h4>Navigation</h4>
		<ul>
			<li>This</li>
			<li>list</li>
			<li>could</li>
			<li>be</li>
			<li>any</li>
			<li>length</li>
		</ul>
	</nav>
	<article class="element-main">
		<h3>Main Content</h3>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Ducimus, veniam, velit? Corporis et hic similique est. Iste amet laudantium, corporis recusandae, unde error harum voluptas, impedit maxime illo cumque consequatur.</p>
	</article>
	<nav class="element-side">
		<h4>Sidebar</h4>
				<ul>
			<li>This</li>
			<li>list</li>
			<li>could</li>
			<li>also</li>
			<li>be</li>
			<li>any</li>
			<li>length</li>
		</ul>
	</nav>
	<aside class="element-cta">
		This is a cta
		<a href="#">Click</a>
	</aside>
</main>
              
            
!

CSS

              
                .container {
	display: grid;
	grid-gap: 15px;
}

@media (min-width: 700px) {
	.container {
		grid-template-columns: repeat(3, 1fr);
		grid-template-rows: auto auto 1fr auto;
		grid-gap: 15px;
	}
	.element-nav {
		grid-column: 3;
		grid-row: 1;
	}
	.element-main {
		grid-column: 1 / span 2;
		grid-row: 1 / span 3;
	}
	.element-side {
		grid-column: 3;
	}
	.element-cta {
		grid-column: 1 / -1;
	}
}

// Visual stuff
*{box-sizing:border-box;}
html,body{margin:0;padding:0;}
.container {font-family: sans-serif;max-width: 1000px;margin: 0 auto;padding: 15px;& > * {padding:20px;border:1px solid gainsboro}}
              
            
!

JS

              
                
              
            
!
999px

Console