Let's say you are using version 1.3.4 of a library with a tilde (~) as your dependency. The most common branch that gets a bug fix is the latest stable branch, and it is not that often that they are backported for older versions. When deciding whether to allow patch or minor level newer versions, it is important to note that old versions usually don't receive patches. Contract for Semantic Versioning in package.json. old functionality deprecated, but operational.You can allow a newer patch level version with tilde (~) and newer minor or patch level version with caret (^). Instead of specifying the exact version to be installed in package.json, npm allows you to widen the range of accepted versions. When executing npm install on a fresh checkout without existing node_modules, npm downloads and installs a version that satisfies package.json for each dependency. Giving npm permission to install newer version ![]() The safest way is to check the module documentation. A module might use a three-part version number, but increment it as they like. Not every module follows Semantic Versioning. Fixing a bug that wasn't handling certain corner-case in _.find() would make the next release 3.9.3. A new optional argument to _.map would make the next release 3.10.0. Major backward incompatible change to, for example, how _.filter() works, would make the next release 4.0.0. Let's take lodash version 3.9.2 as a starting point. simple bug fix to existing functionality increments the patch numberįor any dependency, the release 1.0.0 is considered the first stable release, and the semver contract does not apply to releases before it.new functionality that is backward compatible increments the minor number. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |