@meteora-digital/gallery
v0.0.4
Published
An es6 class to create a simple image gallery.
Downloads
7
Maintainers
Readme
Gallery
Gallery is an es6 Class which can be used to easily make a basic fading gallery with dots and autoplay.
Installation
with webpack
yarn add @meteora-digital/gallery
HTML Usage
<div [ js-my-gallery ]>
<img src"path/to/image_001.jpg" alt="image_001" class="[ js-gallery--item ]">
<img src"path/to/image_002.jpg" alt="image_002" class="[ js-gallery--item ]">
</div>
import Gallery from '@meteora-digital/gallery';
const myGallery = new Gallery(document.querySelector('.js-my-gallery'), {
class: 'js-my-gallery',
autoplay: true,
duration: 5000,
dots: true,
});
.js-my-gallery {
@include meteora-gallery;
}