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.


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.


                <p> Width is just a fallback when flex-basis is missing, and min-width and max-width are just upper and lower limits for the final flex-basis.</p>
<div class="container">
  <div class="one">Item 1</div>
  <div class="two">Item 2</div>
  <div class="three">Item 4</div>
  <div class="four">item 4</div>

  <li>Having <code>flex-basis</code> will ignore any width propery specified to the box.</h1>
<li>If no flex-basis is specified, then the flex-basis falls back to the item's width property.</li>

<li>If no width is specified, then the flex-basis falls back to the computed width of the item's contents.</li>
<li>Providing max-width or min-width would be respected and would be taken into consideration</li>



                .container {
  display: flex;
  width: 1000px;
  background-color: lightyellow;
  border: 2px solid;
.container > div {
  flex-basis: 250px;
  width: 300px; /* this will not be respected. Try changing it min-width */
  height: 200px;
 border: 5px solid hsla(0, 0%, 100%, .5)

 .one {
  background-color: green;
 .two {
  background-color: red;
 .three {
  background-color: blue;
.four {
  background-color: grey;

/* for asthetic reasons only */
html {
  font-size: 125%;
  font-family: Tahoma;