Bower. Helpful but not in the way I expected

JavaScript 3 August 2015 | 0 Comments

The past 2 days have been spent moving our JavaScript app, mostly AngularJS code (yea, don’t have months to rewrite it to ReactJS to be hip!) to use Bower.

It’s great not having reasonably sized JavaScript files in your git repo. Plus it feels super hacker like to watch your build process download the files it needs off the internet…

Enough rambling!

The biggest benefit I’ve found of using Bower is the act it forces you to not just “hack” a change into a library. Instead I have now started submitting PRs to projects on GitHub and getting changes into the libraries themselves.

This means you don’t end up with hacked and modified JavaScript library files floating around in your project.


I’m currently in the dilemma of what to do when a JavaScript library author doesn’t share your vision for their project.

The particular library that is causing me headaches at the moment is Offline.js. In our case we consume a HTTP API (I don’t want to be hit over the head by Jonathan Channon for using the word REST when our API isn’t!) and if that API returns a 503.

From HTTP Dogs

You’d think that’d mean in offline.js that the server is offline and it’d do its thing.


Seems I’m not the only person to have hit this issue with the library.

I guess I can maintain my own fork of the project that treats the 503 the way I want it or simply find another project. Although it’s the best project I’ve found so far for the task except this one problem.

Thoughts anyone?

Leave a Reply