Pen Settings



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


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.


    .gallery-item(v-for="(item, index) in items" :key="index")"item.url" :alt="") The dog gallery


  position: relative
  margin: auto
  width: 80vmin
  display: grid
  grid-gap: 1vmin
  grid-auto-rows: 1fr
  grid-template-columns: repeat(6, 1fr)
  grid-auto-flow: dense
    content: ''
    height: 0
    width: 100%
    padding-bottom: 100%
    grid-column: 1 / 1
    grid-row: 1 / 1
    position: relative
    animation: flash 2s ease infinite alternate
      grid-column: 1 / 1
      grid-row: 1 / 1
      grid-row: span 2
      grid-column: span 1
      grid-row: span 1
      grid-column: span 2
        transform: scale(0.9)
    @for $x from 1 through 5
      @for $y from 1 through 5
        &:nth-child(#{$x * $y})
          animation-delay: (.6s * ($x - 1) + .8s * ($y - 1)) / 1.5
    height: 100%
    width: 100%
    object-fit: cover
    transition: transform .3s ease
    position: absolute

  color: #fff
  letter-spacing: 1vmin
  text-align: center
  position: absolute
  width: 100%
  bottom: calc(100% + 1vmin)
  margin: 0
html, body, .app
  margin: 0
  width: 100%
  height: 100%
  display: flex
  background: #121212
  font-family: 'Six Caps', sans-serif
@keyframes flash
    filter: brightness(1.25) contrast(.85) grayscale(1)


                const api = '';

const param = {
  el: '#app',
  data: {
    items: []
  methods: {
    getItems: function() {
      return fetch(api)
      .then(res => res.json());
  mounted: function() {
    this.getItems().then(data => this.$data.items = data);

const app = new Vue(param);