It works but JShint gives me an error on last line Unexpected ''. This is why I'm unable to compile using gulp and the whole thing crashes.
var yearData = document.querySelectorAll(".timeline-years .have-data");
for (var i = 0, length = yearData.length; i < length; i++) {
if (i % 2 == 0) {
yearData[i].classList.add("bottom-year");
}
}
Not sure whats the fatal flaw here?