1.1.1 • Published 7 months ago

popup-survey v1.1.1

Weekly downloads
-
License
ISC
Repository
-
Last release
7 months ago

TooSlides

A project showing how to create a simple javascript plugin

Getting Started

Get started by downloading the content of this repo. There are two main files of concern: tooSlide.js and tooSlide.css.

Link both files to the page where you want a slider:

<link rel="stylesheet" href="tooSlide.css"> <script src="tooSlide.js>

Using the plugin

The plugin works by converting a list of images on a page to a slider.

Steps

1 Create a container element that will house all sliding images e.g <div class="surveyContainer"></div>

2 Inside the container, add a new div for each image to be used e.g <div class="singleSlide"><img src="path-to-image"></div>

3 Initialize the plugin

var slider = new TooSlides({
    container: ".surveyContainer", // the classname of the overall parent 
    container
    slidesClass: ".singleSlide", //The classname of the sub container
    nextButton: ".next",
    previousButton: ".prev"
})

License

TooSlides is open source software licensed as MIT.

1.1.1

7 months ago

1.0.0

7 months ago