You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/content/misc/faq.ngdoc
+40-10
Original file line number
Diff line number
Diff line change
@@ -25,10 +25,47 @@ So it's definitely not a plugin or some other native browser extension.
25
25
In AngularJS we do not allow intentional breaking changes to appear in versions where only the "patch"
26
26
number changes. For example between 1.3.12 and 1.3.13 there can be no breaking changes. We do allow
27
27
breaking changes happen between "minor" number changes. For example between 1.3.15 and 1.4.0 there
28
-
will be a number of breaking changes. We also allow breaking changes between beta releases of AngularJS.
28
+
are a number of breaking changes. That means AngularJS does not follow
29
+
[semantic versioning (semver)](http://semver.org/) where breaking changes are only
30
+
allowed when the "major" version changes.
31
+
32
+
We also allow breaking changes between beta releases of AngularJS.
29
33
For example between 1.4.0-beta.4 and 1.4.0-beta.5 there may be breaking changes. We try hard to minimize
30
34
these kinds of change only to those where there is a strong use case such as a strongly requested feature
31
-
improvement, a considerable simplification of the code or a measurable performance improvement.
35
+
improvement, a considerable simplification of the code, a measurable performance improvement, or a better
36
+
developer experience (especially with regard to updating to Angular).
37
+
38
+
When we are making a release we generate updates to the changelog directly from the commits. This
39
+
generated update contains a highlighted section that contains all the breaking changes that have been
40
+
extracted from the commits. We can quickly see in the new changelog exactly what commits contain breaking
41
+
changes and so can application developers when they are deciding whether to update to a new version of
42
+
AngularJS.
43
+
44
+
Features with non-breaking changes can also appear in the "patch" version, e.g. in version 1.6.3 there might
45
+
be a feature that is not available in 1.6.2.
46
+
47
+
Finally, deprecation of features might also appear in "minor" version updates. That means the features
48
+
will still work in this version, but sometimes must be activated specifically.
49
+
50
+
#### What is the version compatibility between AngularJS main and optional modules?
51
+
52
+
AngularJS code is separated into a main module ("angular"), and a few different optional modules
53
+
("angular-animate", "angular-route" etc) that are dependant on the main module.
54
+
When a new AngularJS version is released, all modules are updated to the new version.
55
+
This means that the main module and the optional modules must always have the exact same version,
56
+
down the patch number, otherwise your application might break.
57
+
58
+
Therefore you must always explicitly lock down your dependencies, for example in the package.json,
59
+
the following ensures that "angular" and "angular-animate" are always updated to the same version.
60
+
61
+
```
62
+
{
63
+
"angular": "~1.6.0",
64
+
"angular-animate": "~1.6.0"
65
+
}
66
+
```
67
+
68
+
#### How does AngularJS ensure code quality and guard against regressions?
32
69
33
70
When adding new code to branches of AngularJS, have a very stringent commit policy:
34
71
@@ -37,8 +74,7 @@ tests must pass;
37
74
- Commit messages must be written in a specific manner that allows us to parse them and extract the changes
38
75
for release notes.
39
76
40
-
The AngularJS code base has a very large set of unit tests (over 4000) and end to end tests, which are pretty
41
-
comprehensive. This means that a breaking change will require one or more tests to be changed to allow the
77
+
The AngularJS code base has a very large set of unit tests and end-to-end tests. This means that a breaking change will require one or more tests to be changed to allow the
42
78
tests to pass. So when a commit includes tests that are being removed or modified, this is a flag that the
43
79
code might include a breaking change. When reviewing the commit we can then decide whether there really is
44
80
a breaking change and if it is appropriate for the branch to which it is being merged. If so, then we
@@ -49,12 +85,6 @@ over 2000 applications using the test suites of these applications. This allows
49
85
quickly before a release. We've had a pretty good experience with this setup. Only bugs that affect features
50
86
not used at Google or without sufficient test coverage, have a chance of making it through.
51
87
52
-
Lastly, when we are making a release we generate updates to the changelog directly from the commits. This
53
-
generated update contains a highlighted section that contains all the breaking changes that have been
54
-
extracted from the commits. We can quickly see in the new changelog exactly what commits contain breaking
55
-
changes and so can application developers when they are deciding whether to update to a new version of
0 commit comments