https://github.com/nebula-byte/image-switcher
Switch image on any event
https://github.com/nebula-byte/image-switcher
image-switcher switch-image toggle-switches
Last synced: 2 months ago
JSON representation
Switch image on any event
- Host: GitHub
- URL: https://github.com/nebula-byte/image-switcher
- Owner: nebula-byte
- Created: 2020-12-20T05:54:03.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2021-01-25T20:09:26.000Z (over 4 years ago)
- Last Synced: 2025-03-03T19:47:37.247Z (3 months ago)
- Topics: image-switcher, switch-image, toggle-switches
- Language: HTML
- Homepage:
- Size: 2.04 MB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[](https://github.com/prettier/prettier)
# Image Switcher
Add image-switcher to toggle on action.
- No localStorage, only DOM
## Installation
```html
npm i image-switcher
```## Usage
1. Load `image-switcher.min.js` at the foot of your page:
```html
```
2. Add ID to your image switch action:
```html
Switch image
```3. Add image sources and class to your image tag to switch:
```html
![]()
```3. Add animation on images from [animate.style](https://animate.style/):
```html
Switch image
![]()
```