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

              
                <!--
  This is a demo of some advanced ways to color Font Awesome's duotone icons.

All colors are applied using duotone icon's --fa-primary-color and --fa-secondary-color CSS custom properties. Opacity has been reset for all icons in the CSS pane using --fa-secondary-opacity: 1.0 in :root.

Learn more:
https://fontawesome.com/docs/web/style/duotone#coloring-duotone-icons
  -->

<html>
  <head>
    <title>Font Awesome: Duotone Icons - Advanced Coloring</title>
    
    <script src="https://kit.fontawesome.com/5d93eb1089.js" crossorigin="anonymous"></script>
  </head>

  <body>
    <main class="demo-frame">
      <section class="demo">
        <!-- dunkies -->
        <article class="demo-example">
          <i class="fad fa-coffee-togo fa-fw" style="--fa-primary-color: rgb(225,19,131); --fa-secondary-color: rgb(245,130,31);"></i>
        </article>
        
        <!-- UPS -->
        <article class="demo-example">
          <i class="fad fa-shipping-fast fa-fw" style="--fa-primary-color: rgb(83, 63, 49); --fa-secondary-color: rgb(52, 58, 64);"></i>
        </article>
        
        <!-- mcdonalds -->
        <article class="demo-example">
          <i class="fad fa-french-fries fa-fw" style="--fa-primary-color: rgb(218, 41, 28); --fa-secondary-color: rgb(255, 199, 43);"></i>
        </article>
        
        <!-- John Deere -->
        <article class="demo-example">
          <i class="fad fa-tractor fa-fw" style="--fa-primary-color: rgb(54, 124, 42); --fa-secondary-color: rgb(255, 209, 0);"></i>
        </article>
        
        <!-- stahhhhbucks -->
        <article class="demo-example">
          <i class="fad fa-coffee-togo fa-fw" style="--fa-primary-color: antiquewhite; --fa-secondary-color: rgb(5, 118, 85);"></i>
        </article>
      </section>

      <section class="demo">
        <article class="demo-example">
          <i class="fad fa-route-highway fa-fw" style="--fa-primary-color: rgb(240, 62, 61); --fa-secondary-color: rgb(24, 100, 171);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-dog-leashed fa-fw" style="--fa-primary-color: rgb(173, 181, 189); --fa-secondary-color: rgb(224, 49, 48);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-crow fa-fw" style="--fa-primary-color: rgb(50, 154, 240); --fa-secondary-color: rgb(255, 212, 59);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-turtle fa-fw" style="--fa-primary-color: rgb(43, 138, 62); --fa-secondary-color: rgb(170, 227, 75);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-basketball-ball fa-fw" style="--fa-primary-color: rgb(32, 37, 40); --fa-secondary-color: rgb(252, 126, 20);"></i>
        </article>
      </section>

      <section class="demo">
        <article class="demo-example">
          <i class="fad fa-motorcycle fa-fw" style="--fa-primary-color: rgb(134, 142, 150); --fa-secondary-color: rgb(52, 58, 64);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-luchador fa-fw" style="--fa-primary-color: rgb(24, 100, 171); --fa-secondary-color: rgb(240, 62, 61);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-burrito fa-fw" style="--fa-primary-color: rgb(139, 69, 19); --fa-secondary-color: rgb(244, 222, 179);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-globe-snow fa-fw" style="--fa-primary-color: rgb(11, 146, 104); --fa-secondary-color: rgb(165, 216, 255);"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-sleigh fa-fw" style="--fa-primary-color: rgb(201, 42, 42); --fa-secondary-color: rgb(255, 212, 59);"></i>
        </article>
      </section>
    </main>
  </body>
</html>
              
            
!

CSS

              
                :root {
  /* resetting opacity for secondary layer */
  --fa-secondary-opacity: 1.0;
}








/* demo styling - just frosting + presentation - no need to copy this into your project. */
.demo-example {
  font-size: 5rem;
  padding: 1.5rem;
}
              
            
!

JS

              
                
              
            
!
999px

Console