lindell / lindell/JsBarcode

Generate barcode on Angular2 project

Open
#134 7 comments 2 reactions 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

Hi.

I want to use generate a barcode using typeScript and angular2 project.
I've already run `npm install jsbarbode --save ` . After that, I added the reference to the script in **angular-cli.json**
`"scripts": [
"../node_modules/jsbarcode/dist/JsBarcode.all.js"
],`

When I add the module in **app.module.ts** the following error is shown
![image](https://cloud.githubusercontent.com/assets/9375416/23963000/84501856-0975-11e7-8b07-3102e31e6445.png)

**app.module.ts** code:
![image](https://cloud.githubusercontent.com/assets/9375416/23963077/c9472328-0975-11e7-9fa2-050038ba8f26.png)

Does anyone know how to solve it?
Thanks.

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

Reproduce the setup from the issue, starting with the npm install command and the scripts entry in angular-cli.json, then inspect the import in app.module.ts. Confirm the exact module error and whether the Angular2 app can load JsBarcode and generate a barcode without that error.

Written by the indexing model from the issue text.

Assessment

Tech stack
angular, javascript, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.