0.0.1 • Published 7 years ago

vue-qrcode2 v0.0.1

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

vue-qrcode

Install

npm install vue-qrcode2 -S

yarn add vue-qrcode2

QuickStart

require('vue-qrcode/dist/vue-qrcode.css');

// in ES6 modules
import qrcode from 'vue-qrcode';

// in CommonJS
const qrcode = require('vue-qrcode');

// in Global variable
const qrcode = VueQrcode.default;

Vue.use(qrcode);
<qrcode :value="qrCode" :size="300"/>

Params

props

  • background: Background color of the QR code
  • backgroundAlpha: Background alpha of the QR code
  • foreground: Foreground color of the QR code
  • foregroundAlpha: Foreground alpha of the QR code
  • level: Error correction level of the QR code (L, M, Q, H)
  • mime: MIME type used to render the image for the QR code
  • padding: Padding for the QR code (pixels)
  • size: Size of the QR code (pixels)
  • value: Value encoded within the QR code

You may use all of these props to change the format of your QR code.

Preview

qrcode image