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.


  const CONFIG = [
      positionX: 50,
      positionY: 55,
      height: 59,
      width: 55,
      positionX: 74,
      positionY: 15,
      height: 17,
      width: 17,
      positionX: 12,
      positionY: 51,
      height: 24,
      width: 19,

  - for (const ITEM of CONFIG)
    .parallax__item(style=`--width: ${ITEM.width}; --height: ${ITEM.height}; --x: ${ITEM.positionX}; --y: ${ITEM.positionY};`)


  box-sizing border-box
  min-height 100vh
  display grid
  place-items center
  background hsl(210, 20%, 20%)
  position fixed
  top 50%
  left 50%
  height 50vmin
  transform translate(-50%, -50%)
  opacity 0.5
  height 50vmin
  width calc(50 * (484 / 479) * 1vmin)
  background hsla(180, 50%, 50%, 0.25)
  position relative
    position absolute
    left calc(var(--x, 50) * 1%)
    top calc(var(--y, 50) * 1%)
    height calc(var(--height, auto) * 1%)
    width calc(var(--width, auto) * 1%)
    background hsla(0, 50%, 50%, 0.5)
    transform translate(-50%, -50%)