Awesome-viewer
npm i -S @voezy-kit/awesome-viewer
import "@voezy-kit/awesome-viewer/dist/bundle.css";
import { ImgViewer } from "@voezy-kit/awesome-viewer";
const imgViewer = new ImgViewer({
imgList: [
{
// This is the source location of your image
src: 'https://via.placeholder.com/4000x2000',
// And you can put some introduction in it
desc: 'An image of 4000X2000 pixels',
}
],
});
// Show image viewer
imgViewer.show();
// Hide image viewer
imgViewer.hide();
imgViewer.updateState({
imgList: [
{
src: 'https://via.placeholder.com/1000x2000',
desc: 'An image of 1000X2000 pixels',
}
],
})
MIT