0.0.3 • Published 1 year ago

@xby020/potato-slider v0.0.3

Weekly downloads
-
License
-
Repository
github
Last release
1 year ago

Potato slider

an another fancy web slider

Install

npm install @xby020/potato-slider

Usage

import PotatoSlider from '@xby020/potato-slider'

const dom = document.getElementById('slider');
const images = ['imgUrl1','imgUrl2','imgUrl3'];

const slider = new PotatoSlider(dom,images);

// promise
await slider.init();

Switch

// switch by id, which is the index of images
slider.switchById(1);
0.0.3

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago