question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add a bower package

See original GitHub issue

It would be very helpful to have a Bower package for installing PDF.js.

The steps for Bower registration are straightforward:

  1. Create a bower.json to define the package, that would look something like this:
{
  "name": "PDF.js",
  "version": "0.8.477",
  "main": "./PDF.js",
  "ignore": [
    ".jshintrc",
    "**/*.txt"
  ],
  "dependencies": {
    "<name>": "<version>",
    "<name>": "<folder>",
    "<name>": "<package>"
  },
  "devDependencies": {
    "<test-framework-name>": "<version>"
  }
}
  1. Register the package with
$ bower register <my-package-name> <git-endpoint>

Then eager users could install PDF.js with something like bower install PDF.js.

A couple caveats:

  1. the Git tags should be kept up-to-date with the current version (i.e. tags must be pushed);
  2. it would be most effective if a built version of PDF.js were deployed with each tag.

Cheers

Issue Analytics

  • State:closed
  • Created 10 years ago
  • Comments:24 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
Snuffleupaguscommented, Feb 13, 2017

It would be awesome if you support it officially. Thanks.

It’s already supported, and has been for quite some time, please refer to https://github.com/mozilla/pdf.js#using-pdfjs-in-a-web-application. Note how the first search result on https://bower.io/search/?q=pdfjs links to https://github.com/mozilla/pdfjs-dist.

0reactions
mbtakanovcommented, Feb 13, 2017

The issue was closed when bower was not that popular at the time. But look at us now. Everyone is on bower and we can laugh on comments like “Who will ever use XXX from bower?”. It would be awesome if you support it officially. Thanks.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bower — a package manager for the web
To get started, Bower works by fetching and installing packages from all over, taking care of hunting, finding, downloading, and saving the stuff...
Read more >
bower
Bower offers a generic, unopinionated solution to the problem of front-end package management, while exposing the package dependency model ...
Read more >
Manage your Frontend Dependencies with Bower
Bower is a great dependency manager that's specially created to help you manage different frontend libraries. It reduces the time and energy ...
Read more >
Bower Beginner's Guide
The main way to get Bower packages into your project is through the install command followed by the package name you want to...
Read more >
Create and maintain your own bower package - littletechblogger
2. register the package · 2.1 Run command to register package · 2.2 Check successful registration · 3. Add version to the package...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found