Table of contents
Main
dist/
├── vue-barcode.js (71 KB, UMD)
├── vue-barcode.min.js (32 KB, UMD, compressed)
├── vue-barcode.common.js (71 KB, CommonJS)
└── vue-barcode.esm.js (71 KB, ES Module)
Getting started
Install
npm install @xkeshi/vue-barcode
Usage
- Browser:
window.VueBarcode
- CommonJS:
var VueBarcode = require('@xkeshi/vue-barcode')
- ES2015:
import VueBarcode from '@xkeshi/vue-barcode'
Vue.component('barcode', VueBarcode);
<barcode value="Hello, World!" :options="{ displayValue: false }"></barcode>
Props
value
- Type:
String
The value of the barcode.
options
- Type:
Object
The options for the barcode generator. References the JsBarcode's options.
tag
- Type:
String
- Default:
'canvas'
- Options:
'canvas'
,'svg'
and'img'
The tag of the component root element.
Browser support
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Opera (latest)
- Edge (latest)
- Internet Explorer 9+
- 控件地址:
Table of contents
Main
dist/ ├── vue-barcode.js (71 KB, UMD) ├── vue-barcode.min.js (32 KB, UMD, compressed) ├── vue-barcode.common.js (71 KB, CommonJS) └── vue-barcode.esm.js (71 KB, ES Module)
Getting started
Install
npm install @xkeshi/vue-barcode
Usage
- Browser:
window.VueBarcode
- CommonJS:
var VueBarcode = require('@xkeshi/vue-barcode')
- ES2015:
import VueBarcode from '@xkeshi/vue-barcode'
Vue.component('barcode', VueBarcode);
<barcode value="Hello, World!" :options="{ displayValue: false }"></barcode>
Props
value
- Type:
String
The value of the barcode.
options
- Type:
Object
The options for the barcode generator. References the JsBarcode's options.
tag
- Type:
String
- Default:
'canvas'
- Options:
'canvas'
,'svg'
and'img'
The tag of the component root element.
Browser support
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Opera (latest)
- Edge (latest)
- Internet Explorer 9+
https://github.com/xkeshi/vue-barcode - Browser:
Table of contents
Main
dist/
├── vue-barcode.js (71 KB, UMD)
├── vue-barcode.min.js (32 KB, UMD, compressed)
├── vue-barcode.common.js (71 KB, CommonJS)
└── vue-barcode.esm.js (71 KB, ES Module)
Getting started
Install
npm install @xkeshi/vue-barcode
Usage
- Browser:
window.VueBarcode
- CommonJS:
var VueBarcode = require('@xkeshi/vue-barcode')
- ES2015:
import VueBarcode from '@xkeshi/vue-barcode'
Vue.component('barcode', VueBarcode);
<barcode value="Hello, World!" :options="{ displayValue: false }"></barcode>
Props
value
- Type:
String
The value of the barcode.
options
- Type:
Object
The options for the barcode generator. References the JsBarcode's options.
tag
- Type:
String
- Default:
'canvas'
- Options:
'canvas'
,'svg'
and'img'
The tag of the component root element.
Browser support
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Opera (latest)
- Edge (latest)
- Internet Explorer 9+