DEV Community

Discussion on: What's your spookiest coding story?

Collapse
 
jackharner profile image
Jack Harner πŸš€

Designing and launching a Halloween Sale on Halloween morning. Bad planning on my part but I think it turned out pretty well. πŸ˜‚

Collapse
 
jackharner profile image
Jack Harner πŸš€

The blinking eyes were done with CSS Animation. The SCSS Snippet:

 .eyes {
      animation: blink 10s infinite;
      animation-fill-mode: backwards;
      width: 25px;
      position: absolute;

      filter: drop-shadow(0 1px 2px lighten($orange, 5));

      $eyes: 16;

      @for $i from 1 through $eyes {
        &:nth-of-type(#{$i}n) {
          top: random(100) * 1%;
          left: random(100) * 1%;

          animation-delay: ($i / $eyes) * (random(30) - 15) * 1s;
          transform: rotate((random(50) - 25) + deg);
        }
      }
    }