Pen Settings



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


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


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.


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.


                <section class="tabs">

  <ul class="tab-control">
    <li class="tab active-tab">
    <li class="tab">

  <div class="tab-content">

    <div class="content contentOne active">
      <h2>The quick brown fox jumped over the lazy dog.</h2>

    <div class="content contentTwo">
      <h2>The whale beat up some mean sharks.</h2>




                h1 {
  font-size: 24px;

// Tabs

// Content

.tab-content {
  .content {
    display: none;
  .active {
    display: inherit;



var selected_tab;
// Set Opacitys
TweenMax.set(".tab", { opacity: 0.25 });
TweenMax.set(".active-tab", { opacity: 1 });

$(".tabs").each(function(index) {
  var tab = $(this);

    .find(".tab-control li")
    .on("click", function() {
      // Swap Tab Class
      $(this).addClass("active-tab");".tab-control li", 0.5, { opacity: 0.25 });, 0.5, { opacity: 1 });

      selected_tab = $(this).text();


      function animate_content(selected_tab) {
        var current_tab = $(".tabs").find(".content");, 0.5, {
          opacity: 0,
          onComplete: function() {
              .find(".tab-content .content")
              .find(".content" + selected_tab)
        console.log(".content" + selected_tab);".content" + selected_tab, 0.5, { opacity: 1, delay: 0.5 });