link

link $ bower link $ bower link <name> [<local name>] The link functionality allows developers to easily test their packages. Linking is a two-step process. Using ‘bower link’ in a project folder will create a global link. Then, in some other package, bower link <name> will create a link in the components folder pointing to the previously created link. This allows you to easily test a package because changes will be reflected immediately. When the link is no longer necessary, s

list

list $ bower list [<options>] List local packages and possible updates. list options -p, --paths: Generates a simple JSON source mapping -r, --relative: Make paths relative to the directory config property, which defaults to bower_components

init

init $ bower init Interactively create a bower.json file

help

help $ bower help <command> Display help information about Bower

info

info $ bower info <package> $ bower info <package> [<property>] $ bower info <package>#<version> [<property>] Displays overall information of a package or of a particular version.

home

home $ bower home $ bower home <package> $ bower home <package>#<version> Opens a package homepage into your favorite browser. If no <package> is passed, opens the homepage of the local package.

Creating Packages

bower.json Packages are defined by a manifest file bower.json. This is similar to Node’s package.json or Ruby’s Gemfile. Interactively create a bower.json with bower init $ bower init Specification Detailed specification of bower.json file can be found in bower/spec repository. Maintaining dependencies Using bower install <package> --save will add <package> to your project’s bower.json dependencies array. # install package and add it to bower.json dependencies $ bower install <pa

Configuration

Bower can be configured using JSON in a .bowerrc file. For example: { "directory": "app/components/", "analytics": false, "timeout": 120000, "registry": { "search": [ "http://localhost:8000", "https://bower.herokuapp.com" ] } } Placement & Order The config is obtained by merging multiple configurations by this order of importance: CLI arguments via --config Environment variables Local .bowerrc located in the current working directory All .bowerrc files upwards

cache

cache $ bower cache <command> [<args>] Manage bower cache cache clean $ bower cache clean $ bower cache clean <name> [<name> ...] $ bower cache clean <name>#<version> [<name>#<version> ..] Cleans cached packages cache list $ bower cache list $ bower cache list <name> [<name> ...] Lists cached packages