lindell / lindell/JsBarcode

Suggestion: add mixed mode initiation sample

Open
#304 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
5.9k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

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()

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No documentation file or test is named. Start by locating the existing JsBarcode examples or initiation documentation, then add the provided HTML and JavaScript mixed-mode example; done means users can see how to supply the value as an attribute and other options during initiation.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.