An Ember addon to render barcodes using the JsBarcode library. See the demo to experiment with many of the barcode options.
The addon adds accessibility attributes and elements to the generated barcodes. See the Accessibility section below.
- Ember.js v3.12 or above
- Ember CLI v2.13 or above
- Embroider safe and optimized
- Node.js v10 or above
$ ember install ember-cli-barcode
By default all barcode types are added to your app. See the build configuration section for slimming your build
To render a barcode provide the barcode value and the default options will generate a CODE128 barcode:
which renders:
By default, barcodes are rendered using the svg
element. The element can be changed to img
or canvas
using the tagName property:
Use the img
tag if you want the ability to right-click copy or save the displayed barcode.
See the Options readme for detailed barcode options.
See the Contributing guide for details.