<button class="play">Play</button>
<div class="container">
  <div class="box a"></div>
  <div class="box b"></div>
  <div class="box c"></div>
  <div class="box d"></div>
  <div class="box e"></div>
  <div class="box f"></div>
  <div class="box g"></div>
  <div class="box h"></div>
  <div class="box i"></div>
  <div class="box j"></div>
</div>
body {
  margin: 20px auto;
  font-family: "Lato";
  font-weight: 300;
  width: 600px;
  font-size: 1.3em;
}

.box {
  height: 20px;
  background: black;
  margin-top: 5px;
  position: relative;
  padding: 5px;
  font-size: 1rem;
  color: orange;
  font-weight: bold;
  border-radius: 6px;
}

.box:before {
    display: block;
    width: 300px;
}

.a:before {
  content: "Ease In";
}

.b:before {
  content: "Sin In";
}

.c:before {
  content: "Quad In";
}

.d:before {
  content: "Cubic In";
}

.e:before {
  content: "Quart In";
}

.f:before {
  content: "Quint In";
}

.g:before {
  content: "Expo In";
}

.h:before {
  content: "Circ In";
}

.i:before {
  content: "Back In";
}

.j:before {
  content: "Elastic In";
}

.container {
  perspective: 100px;
}

button{
  background: orange;
  border: none;
  color: white;
  font-family: "Lato";
  padding: 10px 15px;
  cursor: pointer;
  outline: none;
  margin-top: 10px;
  margin-bottom: 30px;
  font-weight: 300;
}
var allBoxes = document.querySelectorAll(".box");

var animations = new Array();

var easings = ['ease.in', 'sin.in', 'quad.in', 'cubic.in', 'quart.in', 'quint.in', 'expo.in', 'circ.in', 'back.in', 'elastic.in'];

allBoxes.forEach(function(box, index) {
  var animation = new mojs.Html({
    el: box,
    width: {
      0: 550,
      duration: 4000,
      repeat: 8,
      isYoyo: true,
      easing: easings[index]
    }
  });
  animations.push(animation);
});

document.querySelector(".play").addEventListener("click", function() {
  animations.forEach(function(anim) {
    anim.play();
  });
});

External CSS

  1. https://fonts.googleapis.com/css?family=Lato:300

External JavaScript

  1. https://cdnjs.cloudflare.com/ajax/libs/mo-js/0.288.2/mo.min.js
  2. https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js