-->

How to do a minimal install using Bower

2019-06-18 07:12发布

问题:

I'm using Bower to manage all the front end libraries and tools I'm using for a project. My bower.json file looks like this

{
  "name": "New Project",
  "version": "0.1.0",
  "dependencies": {
    "jquery": "~1.11.1",
    "bootstrap": "~3.3.4"
  }
}

When I run bower install it creates a jquery/src directory with a ton of JS files that I don't need and won't use. I just need the jquery.min.js file. Is there a way to control how much is installed and just do a minimal install?

回答1:

Only Grab the Files You Need While Using Bower

links:

  1. explanation: https://scotch.io/tutorials/only-grab-the-files-you-need-while-using-bower
  2. direct: https://github.com/blittle/bower-installer