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. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

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

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 Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

HTML

              
                <script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>
<nav id="navbar">
<header>Technical documentation</header>
<a href="#Javascript_and_Java" class="nav-link">Javascript and Java</a>
<a href="#Song_lyrics" class="nav-link">Song lyrics</a>
<a href="#colors" class="nav-link">colors</a>
<a href="#Ice_cream_flavors" class="nav-link">Ice cream flavors</a>
  <a href="#Fruits" class="nav-link">fruits</a>
</nav>


<main id="main-doc">
  <h1>Weird reqs</h1>
    <section class="main-section" id="Javascript_and_Java" >
        <header>Javascript and Java</header>
        <p>single line comments<code>//this is a comment</code></p>
        <p>multi line comments
            <code>/* you can have many lines/*</code>
        </p>
        <p>return statements
            <code>return String;</code>
        </p>
        <p>objects
            <code>
                function Car(wheels, doors) {
                    this.wheels = wheels,
                    this.doors = doors
                }
            </code>
        </p>
        <p>constructors
            <code>
                let transam = new Car();
            </code>
        </p>
    </section>
    <section class="main-section" id="Song_lyrics">
      <header>Song lyrics</header>
      <p>
      <ul>
        <li>Once</li>
        <li>Twice</li>
        <li>Three</li>
        <li>Times a </li>
        <li>Lady</li>
    </ul></p></section>
    <section class="main-section" id="colors">
      <header>colors</header>
      <p>Blue or green only</p>
    </section>
    <section class="main-section" id="Ice_cream_flavors">
      <header>Ice cream flavors</header>
      <p>All of them</p>
  </section>
   <section class="main-section" id="Fruits">
     <header>Fruits</header>
     <p>Tomtoes are technically fruits.</p>
     <p>I prefer sweet fruits like pineapple.</p>
  </section>
</main>
              
            
!

CSS

              
                #navbar {
  position: fixed;
  left: 20px;
  display: block;
  width:250px;
  top: 50px;
  
  a{
    float:left;
    width:100%;
    }
}
main{
  float:left;
  margin-left: 270px;
}
@media (max-width: 480px){
  #navbar{
    position: fixed;
    float: none;
    height: 50px;
    overflow-y:scroll;
  }
}
              
            
!

JS

              
                
              
            
!
999px

Console