C
C
Cosmonaut.2018-02-14 10:01:29
Layout
Cosmonaut., 2018-02-14 10:01:29

How to create such a slider?

Hello. Please help me how to create such a slider?
5a83deaa68aaa540203330.jpeg

Answer the question

In order to leave comments, you need to log in

3 answer(s)
V
Vasily Vasilyev, 2018-02-14
@Alizoda

As the simplest option:
A container with overflow-x: hidden, it has a flexbox line (wider than the container) with fixed-width divs, logos with a background ( background-size: contain;), a js function for scrolling the line left-right when clicking on the arrows.

<a id="arrowLeft" href="#" onclick="myFunction(-1)"></a>
<a id="arrowRight" href="#" onclick="myFunction(1)"></a>

function myFunction(direction){
//...
}

About libs: the fewer dependencies, the better. To put it simply: what can be done without third-party libraries - do it without third-party libraries. Less govnokoda - happy mug and you and the customer.
PS: if it's still not clear - look for options on codepen.

N
Nikita, 2018-02-14
@Rema1ns

take one of the popular slick or owl sliders and create.
You will only need to add your own styles for the arrows

I
Islam Ibakaev, 2018-02-14
@devellopah

a simple slider, you take slick and there in the slidePerShow property (I'm not sure if I wrote it correctly, well, you'll figure it out), you specify 5.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question