В моей функции swiperLoad()
я обязан добавить // eslint-disable-next-line no-unused-expressions
, но ничего не работает
import React, {Component} from "react";
import Project from "./Project";
import $ from 'jquery';
import Swiper from "swiper";
class Main extends Component {
componentDidMount() {
swiperLoad();
}
render() {
return <>
<header className="head" data-parallax="scroll" data-image-src="/images/home1.png" data-speed="0.4">
<div className="container">
<div className="outer">
<div className="inner text-center">
<div className="animate-title">
<ul className="texts">
<li data-in-effect="fadeInUp" data-out-effect="fadeOutDown">La Force du Nombre!</li>
<li data-in-effect="fadeInUp" data-out-effect="fadeOutDown">La Cagnotte en Ligne
Solidaire!
</li>
<li data-in-effect="fadeInUp" data-out-effect="fadeOutDown">Every Kid is a Genius!
</li>
<li data-in-effect="fadeInUp" data-out-effect="fadeOutDown">Vous Pouvez Faire la
Différence!
</li>
</ul>
</div>
<h2>FAITES AVANCER VOS CAUSES</h2>
</div>
</div>
</div>
</header>
</>
}
}
const swiperLoad = () => {
// eslint-disable-next-line no-unused-expressions
$(function (e) {
e(".page-loader").fadeOut("slow"), e(".disable-loader").on("click", function () {
e(".page-loader").fadeOut("slow")
}), e(".counter").counterUp({delay: 10, time: 1e3}), e(".animate-title").textillate({
loop: !0,
type: "word",
"in": {delay: 120},
out: {delay: 120}
}), e(".background-slider").backstretch(["http://placehold.it/1080x718?text=kids-img-1", "http://placehold.it/1080x718?text=kids-img-2", "http://placehold.it/1080x718?text=kids-img-3"], {
duration: 3e3,
fade: 750
});
var a = new Swiper(".swiper-container", {pagination: ".swiper-pagination", paginationClickable: !0});
// eslint-disable-next-line no-unused-expressions
console.log(a), e(window).on("scroll resize", function () {
return e(window).scrollTop() >= 75 && e("body").addClass("fixed-header"), e(window).scrollTop() < 75 ? e("body").removeClass("fixed-header") : void 0
}), e(".campaign-info").matchHeight(), e(".same-ht").matchHeight(), e(".owl-carousel-single").owlCarousel({
loop: !1,
navRewind: !1,
margin: 10,
dots: !0,
nav: !1,
autoplay: !1,
navText: [],
items: 1
})
});
};
export default Main;