I'm confused about the proper way to use Bower. When I install components I get a large bower_components
directory that contains much more than just the files I am interested in. For example, if you install jQuery with bower you get a ton of source files.
I only want to keep the files that are absolutely needed in my project to run. Is there a general solution for getting rid of the unneeded files copied down by bower? How do I know what to get rid of? Why are these even there?
Of course, if even if I do delete them, the next time I run bower install
they will all come back.
What the deal here? How are you supposed to manage this stuff?
There are several answers to this question already posted here. My opinion is that you just use the files you need and leave the rest as they were. You're not checking in the /bower_components
folder with version control anyway so the only harm done is using up a tiny bit of disk space (for example: jQuery installed from Bower is a 2,2MB folder in total).
Edit: I found a grunt plugin called grunt-bower-task that let's you fine-tune your bower installs.