Skip to content

erwe222/vue-picture-viewer

 
 

Repository files navigation

vue-picture-viewer

vue-picture-viewer is a picture viewer for Vue.js.

component view

Demo

LiveDemo

Install

$ npm install vue-picture-viewer

Import

Import using module

  // in ES6 modules
  import vuePictureViewer from 'vue-picture-viewer'

  // in CommonJS
  const vuePictureViewer = require('vue-picture-viewer')
  
  Vue.use(vuePictureViewer)

Import using script tag

   <script src="../node_modules/vue-picture-viewer/vue-picture-viewer.js"></script>
   
   // as a component reference
   <vue-picture-viewer></vue-picture-viewer>

Usage

Work on Vue instance

   <vue-picture-viewer :imgData="imgData" :switch="true"></vue-picture-viewer>

Options

props

options type Description Default
imgData Array imgUrl and imgName -
switch Boolean Whether to enable thumbnails true

License

MIT

Copyright (c) 2018-present, Joy Sang

About

一款基于Vue2x的图片预览插件

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Vue 87.1%
  • JavaScript 11.9%
  • HTML 1.0%