JsBarcode icon indicating copy to clipboard operation
JsBarcode copied to clipboard

Suggestion: add mixed mode initiation sample

Open zorgoz opened this issue 4 years ago • 0 comments

As there is the long-time open issue #138 that does not enable flat to be specified as HTML attribute, and just not to repeat the same attributes on many elements, I wanted to initialize JSBarcode with mixed-mode: the value as an attribute, anything else during initiation. As I haven't found any sample on how to do that, I have begone to experiment. And here it is

<svg class="barcode" jsbarcode-value="123456789012"></svg>
JsBarcode('.barcode').options({
  format:'ean13', 
  height:25, 
  displayValue: false,
  flat:true
  // and so on
  }).init()

zorgoz avatar Sep 02 '19 08:09 zorgoz