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

              
                .block
  Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
              
            
!

CSS

              
                @import compass

@import url('https://fonts.googleapis.com/css?family=Open+Sans:400,300,700')

$family-sans: 'Open Sans','ヒラギノ角ゴ Pro W3','Hiragino Kaku Gothic Pro','メイリオ',Meiryo,'MS Pゴシック',sans-serif

=font($size: 1em, $line-height: normal, $weight: normal, $family: 'sans')
  font-family: $family-sans
  font-size: $size
  font-weight: $weight
  line-height: $line-height

=wordwrap-fadeout($h: 40px, $p: 10px, $c: #fff)
  position: relative
  overflow: hidden
  @if $p > 1
    &:before
      content: ''
      position: absolute
      bottom: 0
      left: 0
      width: 100%
      height: $p
      background: $c
  &:after
    +background-image(linear-gradient(to top, rgba($c,1), rgba($c,0)))
    content: ''
    position: absolute
    bottom: $p
    left: 0
    width: 100%
    height: $h

body
  padding: 50px
  background: #AEC6CF
  
.block
  +wordwrap-fadeout(60px, 0, #AEC6CF)
  +font(16px, 1em, bold)
  display: block
  width: 300px
  height: 120px
  margin: 0 auto
  line-height: 1.6em
  
              
            
!

JS

              
                
              
            
!
999px

Console