let activeClass = function(posElem) {
activeSlide = document.querySelector('.slide__active');
activeSlide.classList.remove('slide__active');
activeSlide.posElem.classList.add('slide__active'); // classList a not defiend
activeSlide = document.querySelector('.slide__active');
}
activeClass('nextElementSibling');
activeClass('previousElementSibling');