Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bowers .bower.json file version property

Tags:

bower

bower.json has a property named version. Bower uses tags to manage versions. I'm wondering what is this property uses for then? Does it have to match the committed tag? If not can it cause issues? Is this another way of managing versions? does bower follow this in any way?

like image 820
Sagivf Avatar asked Jul 19 '14 20:07

Sagivf


People also ask

What is bower JSON file?

bower. json exists inside of a package. (at the root directory of a package). A package is contained code which other developers/packages can use. So if you make your own package, you need a bower.

How do you get the latest version of the dependencies as per the JSON file installed?

You can find the latest version of the npm added in package. json file. If you want to add the latest version either you can run npm install or npm install @latest .

What does bower json get created?

Creating a bower. json to identify the dependencies in your project, so you'll want to make sure you create this bower. json first. You can do that by running bower init from your command line. Upon hitting enter, Bower immediately runs you through a series of questions and creates the bower.

Is bower deprecated?

Bower has been deprecated. However, it is not recommended given the rise of other package managers like NPM.


1 Answers

Bower currently ignores version from bower.json.

If the version in bower.json doesn't match git tag, you get a warning, and the version entry in generated .bower.json is fixed (version in bower.json stays the same).

Among others that's why bower plugins should consume.bower.json instead bower.json.

You can safely remove version from your bower.json. Bower only respects git tags.

Most probably it won't be used even in the future.

like image 152
sheerun Avatar answered Nov 13 '22 15:11

sheerun