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

              
                <p>(resize the screen horizontally)</p> <br>

<user-card>
  <picture class='avatar'>
    <img src='https://sheriffderek.consulting/resources/social/insignia/512.png'>
  </picture>

	<section class='info'>
		<h1 class='name'>Derek Wood</h1>
  	<h2 class='position'>Principal @ Perpetual&nbsp;Education</h2>
	</section>

  <footer class='actions'> <!-- might be many! -->
    <a class='link' href='https://sheriffderek.consulting' target='sh'>
      <span>Say hi!</span>
    </a>
  </footer>
</user-card>


<!-- probably would just make an element called <actions> -->
<!-- it depends if you are in favor of 1 footer element only per site or not -->
<!-- we can debate the markup -->

              
            
!

CSS

              
                /* reset ^ included in cog */
/* variables mixins included from another pen to show this as a stand alone component */

user-card
	display: block // custom elements are 'inline' by default
	display: flex //
	flex-direction: column
	align-items: flex-start
	padding: $pad
	.avatar
		max-width: 80px
		circle()
	.name
		calm-voice()
		margin-top: $pad*.5
	.position
		micro-copy()
		margin-top: $pad*.5
	.actions
		display: flex
		margin-top: $pad
	@media (max-width: 399px)
		.link
			standard-button()
	@media (min-width: 400px)
		roundy-corners()
		drop-shadow()
		max-width: 400px /* should be decided by parent */
		display: grid
		/* or whatever - just for fun */
		grid-template-areas: 
    	"visual info info info info"\
    	"visual actions actions actions actions"; 
			// this isn't great ^ haha
			// but you get the point
		.avatar
			grid-area: visual
		.info
			grid-area: info
		.actions
			grid-area: actions
		.link
			micro-copy()
			color: blue
			text-decoration: underline

			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
			
p
	opacity: .6

              
            
!

JS

              
                

new Vue({
	el: '#context',
	
	
});
              
            
!
999px

Console