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

              
                <script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>

<main id="main">
  <h1 id="title">George Washington</h1>
  <div id="img-div">
    <figure id="img-div">
      <img id="image" src="https://upload.wikimedia.org/wikipedia/commons/thumb/b/b6/Gilbert_Stuart_Williamstown_Portrait_of_George_Washington.jpg/800px-Gilbert_Stuart_Williamstown_Portrait_of_George_Washington.jpg" alt="First president of United States"/>
      <figcaption id="img-caption">
    Mr. George Washington, American political leader, military general, statesman, the first president of United States.
      </figcaption>
    </figure>
    <section id="tribute-info">
      <h3 id="headline">Here's his journey of fighting for freedom and democracy for United States:</h3>
      <ul>
        <li><strong>1763</strong> - He and other colonists were angered by the Royal Proclamation of 1763 .</li>
        <li><strong>1774</strong> - Washington attended the First Virginia Convention, where he was selected as a delegate to the First Continental Congress.
        </li>
        <li><strong>1775</strong> - Congress created the Continental Army on June 14, 1775, and Samuel and John Adams nominated Washington to become its commander in chief.    
        </li>
                <li><strong>1776</strong> - Washington proceeded to New York City, arriving on April 13, 1776, and began constructing fortifications there to thwart the expected British attack.   
        </li>
        <li><strong>1777</strong> - Washington's army of 11,000 went into winter quarters at Valley Forge north of Philadelphia in December 1777.</li>
        <li><strong>1783</strong> - The peace negotiations started, the British gradually evacuated troops from Savannah, Charlestown, and New York by 1783, and the French army and navy likewise departed.</li>
      </ul>
       <blockquote
      cite="http://news.rediff.com/report/2009/sep/14/pm-pays-tribute-to-father-of-green-revolution-borlaug.htm"
    >
      <p>
        “Observe good faith and justice towards all nations; cultivate peace and harmony with all.”
      </p>
      <cite>-- George Washington</cite>
    </blockquote>
      <h3>If you are interested to learn more about this great leader's in history, check out <a id="tribute-link" href="https://en.wikipedia.org/wiki/George_Washington" target="_blank">George Washington's Wikipedia entry!</a></h3>
    </section>
  </div>
</main>
              
            
!

CSS

              
                html {
  /* Info: 1rem === 10px */
  font-size: 1rem;
}

body {
  font-family: Frutiger, "Frutiger Linotype", Univers, Calibri, "Gill Sans", "Gill Sans MT", "Myriad Pro", Myriad, "DejaVu Sans Condensed", "Liberation Sans", "Nimbus Sans L", Tahoma, Geneva, "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 1.2rem;
  background-color: brown;
  line-height: 1.5;
  text-align: center;
  color: #333;
  margin: 0;
}

a {
  color: #74638f;
}

a:hover {
  color: #477ca7;
}
#tribute-info{
  color: white;
}

#main {
  margin: 30px 8px;
  padding: 15px;
  border-radius: 5px;
}

@media (max-width: 460px) {
  #main {
    margin: 0;
  }
}

img {
  max-width: 100%;
  display: block;
  height: auto;
  margin: 0 auto;
}
#img-div {
  background: black;
  padding: 10px;
  margin: 0;
}

#img-caption {
  margin: 15px 0 5px 0;
  color: white;
}

@media (max-width: 460px) {
  #img-caption {
    font-size: 1.4rem;
  }
}

#headline {
  margin: 50px 0;
  text-align: center;
}

ul {
  max-width: 550px;
  margin: 0 auto 50px auto;
  text-align: left;
  line-height: 1.6;
}

li {
  margin: 16px 0;
}

blockquote {
  font-style: italic;
  max-width: 545px;
  margin: 0 auto 50px auto;
  text-align: left;
}
              
            
!

JS

              
                
              
            
!
999px

Console