Skip to content

Commit 4d311f9

Browse files
committed
chore: npm versioning language adjustments
1 parent a1de907 commit 4d311f9

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

understanding-packages.md

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,22 @@ There are also quite a number of plugins maintained and developed by the NativeS
3636

3737
## NPM Versioning
3838

39-
NativeScript packages do not follow Semantic Versioning for a particular reason. Since NativeScript enables the empowerment of JavaScript with native platform APIs we strive to do major releases around platform API tooling upgrade cycles (Things like Xcode, Android Studio, etc.). Major framework releases are generally released every six months (~March and ~September which is often the timeframe platform API toolchains are also updated), while minor and patch releases may be released as often as every week. Patch releases should never contain breaking changes, however minor, and major releases can. We strive to note any breaking changes in the Changelogs, to make upgrades as easy as possible.
39+
NativeScript packages do not follow Semantic Versioning for a particular reason. Since NativeScript enables the empowerment of JavaScript with native platform APIs we strive to do major releases around platform API tooling upgrade cycles (Things like Xcode, Android Studio, etc.). Major/Minor releases are generally released every six months (~March and ~September which is often the timeframe platform API toolchains are also updated), while patch releases may be released as often as every week. Patch releases should never contain breaking changes, however minor and major releases can. We strive to always note any breaking changes in the Changelogs, to make upgrades as easy as possible.
4040

4141
We always recommend using `~` (tilda) with any NativeScript package versions in your projects as that will ensure anytime you execute a `ns clean` against your project that the next run will pull down the latest patch release fixes to anything we may have released.
4242

43-
For example, when referencing the `@nativescript/core` package, you could use a fixed version constraint such as `8.0.0`, or alternatively `~8.0.0` to allow installing patch updates automatically after a project clean.
43+
For example, when referencing the `@nativescript/*` packages, we always recommend the following:
44+
45+
```
46+
"dependencies": {
47+
"@nativescript/core": "~8.1.0"
48+
},
49+
"devDependencies": {
50+
"@nativescript/android": "~8.1.0",
51+
"@nativescript/ios": "~8.1.0",
52+
"@nativescript/types": "~8.1.0",
53+
"@nativescript/webpack": "~5.0.0"
54+
}
55+
```
56+
57+
This will ensure bug fix patch updates are automatically installed when cleaning your projects in addition to ensuring that no major version changes may accidentally pulled it which may contain breaking changes.

0 commit comments

Comments
 (0)