X Tutup
Skip to content

Commit 140a878

Browse files
committed
chore(changelog): regenerate changelog for beta.16 including refactor
- the script explicitly takes input for the starting tag. - the script only prepends changes.
1 parent b62bccf commit 140a878

File tree

2 files changed

+104
-20
lines changed

2 files changed

+104
-20
lines changed

CHANGELOG.md

Lines changed: 86 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,18 @@
2323

2424
### Features
2525

26+
* **codegen:** produce `.ngfactory.dart/ts` files instead of `.template.dart/ts` files. ([c06b0a2](https://github.com/angular/angular/commit/c06b0a2))
27+
* **core:** add `Query.read` and remove `DynamicComponentLoader.loadIntoLocation`. ([efbd446](https://github.com/angular/angular/commit/efbd446))
28+
* **core:** introduce ComponentFactory. ([0c600cf](https://github.com/angular/angular/commit/0c600cf))
29+
* **core:** separate reflective injector from Injector interface ([0a7d10b](https://github.com/angular/angular/commit/0a7d10b))
30+
* **core:** support importUri in StaticReflector ([3e11422](https://github.com/angular/angular/commit/3e11422)), closes [#8195](https://github.com/angular/angular/issues/8195)
31+
* **core:** support non reflective bootstrap. ([9092ac7](https://github.com/angular/angular/commit/9092ac7))
2632
* **html_lexer:** support special forms used by i18n { exp, plural, =0 {} } ([7f29766](https://github.com/angular/angular/commit/7f29766))
2733
* **html_parser:** support special forms used by i18n { exp, plural, =0 {} } ([7c9717b](https://github.com/angular/angular/commit/7c9717b))
2834
* **i18n:** add custom placeholder names ([bb9fb21](https://github.com/angular/angular/commit/bb9fb21)), closes [#7799](https://github.com/angular/angular/issues/7799) [#8057](https://github.com/angular/angular/issues/8057)
2935
* **i18n:** add support for nested expansion forms ([c6244d1](https://github.com/angular/angular/commit/c6244d1)), closes [#7977](https://github.com/angular/angular/issues/7977)
3036
* **i18n:** support plural and gender special forms ([88b0a23](https://github.com/angular/angular/commit/88b0a23))
37+
* **Location:** out of router and into platform/common ([b602bd8](https://github.com/angular/angular/commit/b602bd8)), closes [#7962](https://github.com/angular/angular/issues/7962)
3138
* **NgTemplateOutlet:** add NgTemplateOutlet directive ([f4e6994](https://github.com/angular/angular/commit/f4e6994)), closes [#7615](https://github.com/angular/angular/issues/7615) [#8021](https://github.com/angular/angular/issues/8021)
3239
* **router:** add Router and RouterOutlet ([5a897cf](https://github.com/angular/angular/commit/5a897cf)), closes [#8173](https://github.com/angular/angular/issues/8173)
3340
* **router:** add router metadata ([ef67a0c](https://github.com/angular/angular/commit/ef67a0c))
@@ -36,10 +43,72 @@
3643
* **router:** implement RouterUrlParser ([f698567](https://github.com/angular/angular/commit/f698567))
3744
* **test:** Implement fakeAsync using the FakeAsyncTestZoneSpec from zone.js. ([bab81a9](https://github.com/angular/angular/commit/bab81a9)), closes [#8142](https://github.com/angular/angular/issues/8142)
3845
* **tests:** manage asynchronous tests using zones ([8490921](https://github.com/angular/angular/commit/8490921)), closes [#7735](https://github.com/angular/angular/issues/7735)
46+
* **view_compiler:** codegen DI and Queries ([2b34c88](https://github.com/angular/angular/commit/2b34c88)), closes [#6301](https://github.com/angular/angular/issues/6301) [#6567](https://github.com/angular/angular/issues/6567)
3947

4048

4149
### BREAKING CHANGES
4250

51+
* - pipes now take a variable number of arguments, and not an array that contains all arguments.
52+
53+
* inject can no longer wrap fakeAsync while fakeAsync can wrap inject. So the order in existing tests with inject and fakeAsync has to be switched as follows:
54+
Before:
55+
```
56+
inject([...], fakeAsync((...) => {...}))
57+
```
58+
After:
59+
```
60+
fakeAsync(inject([...], (...) => {...}))
61+
```
62+
You will also need to add the dependency
63+
`'node_modules/zone.js/dist/fake-async-test.js'`
64+
as a served file in your Karma or other test configuration.
65+
66+
* - Injector was renamed into `ReflectiveInjector`,
67+
as `Injector` is only an abstract class with one method on it
68+
- `Injector.getOptional()` was changed into `Injector.get(token, notFoundValue)`
69+
to make implementing injectors simpler
70+
- `ViewContainerRef.createComponent` now takes an `Injector`
71+
instead of `ResolvedProviders`. If a reflective injector
72+
should be used, create one before calling this method.
73+
(e.g. via `ReflectiveInjector.resolveAndCreate(…)`.
74+
75+
* - `DynamicComponentLoader.loadIntoLocation` has been removed. Use `@ViewChild(‘myVar’, read: ViewContainerRef)` to get hold of a `ViewContainerRef` at an element with variable `myVar`. Then call `DynamicComponentLoader.loadNextToLocation`.
76+
- `DynamicComponentLoader.loadNextToLocation` now takes a `ViewContainerRef` instead of an `ElementRef`.
77+
- `AppViewManager` is renamed into `ViewUtils` and is a mere private utility service.
78+
79+
* - `Compiler` is renamed to `ComponentResolver`,
80+
`Compiler.compileInHost` has been renamed to `ComponentResolver.resolveComponent`.
81+
- `ComponentRef.dispose` is renamed to `ComponentRef.destroy`
82+
- `ViewContainerRef.createHostView` is renamed to `ViewContainerRef.createComponent`
83+
- `ComponentFixture_` has been removed, the class `ComponentFixture`
84+
can now be created directly as it is no more using private APIs.
85+
86+
* `Location` and other related providers have been moved out of `router` and into `platform/common`. `BrowserPlatformLocation` is not meant to be used directly however advanced configurations may use it via the following import change.
87+
Before:
88+
```
89+
import {
90+
PlatformLocation,
91+
Location,
92+
LocationStrategy,
93+
HashLocationStrategy,
94+
PathLocationStrategy,
95+
APP_BASE_HREF}
96+
from 'angular2/router';
97+
import {BrowserPlatformLocation} from 'angular2/src/router/location/browser_platform_location';
98+
```
99+
After:
100+
```
101+
import {
102+
PlatformLocation,
103+
Location,
104+
LocationStrategy,
105+
HashLocationStrategy,
106+
PathLocationStrategy,
107+
APP_BASE_HREF}
108+
from 'angular2/platform/common';
109+
import {BrowserPlatformLocation} from 'angular2/src/platform/browser/location/browser_platform_location';
110+
```
111+
43112
* `injectAsync` is now deprecated. Instead, use the `async` function
44113
to wrap any asynchronous tests.
45114

@@ -67,21 +136,24 @@ it('should wait for returned promises', async(() => {
67136
}));
68137
```
69138

70-
* inject can no longer wrap fakeAsync while fakeAsync can wrap inject. So the order in existing tests with inject and fakeAsync has to be switched as follows:
71-
Before:
72-
```
73-
inject([...], fakeAsync((...) => {...}))
74-
```
75-
After:
76-
```
77-
fakeAsync(inject([...], (...) => {...}))
78-
```
139+
* - Renderer:
140+
* renderComponent method is removed form `Renderer`, only present on `RootRenderer`
141+
* Renderer.setDebugInfo is removed. Renderer.createElement / createText / createTemplateAnchor
142+
now take the DebugInfo directly.
143+
- Query semantics:
144+
* Queries don't work with dynamically loaded components.
145+
* e.g. for router-outlet: loaded components can't be queries via @ViewQuery,
146+
but router-outlet emits an event `activate` now that emits the activated component
147+
- Exception classes and the context inside changed (renamed fields)
148+
- DebugElement.attributes is an Object and not a Map in JS any more
149+
- ChangeDetectorGenConfig was renamed into CompilerConfig
150+
- AppViewManager.createEmbeddedViewInContainer / AppViewManager.createHostViewInContainer
151+
are removed, use the methods in ViewContainerRef instead
152+
- Change detection order changed:
153+
* 1. dirty check component inputs
154+
* 2. dirty check content children
155+
* 3. update render nodes
79156

80-
You will also need to add the dependency
81-
`'node_modules/zone.js/dist/fake-async-test.js'`
82-
as a served file in your Karma or other test configuration.
83-
84-
* - pipes now take a variable number of arguments, and not an array that contains all arguments.
85157

86158

87159
<a name="2.0.0-beta.15"></a>
@@ -2621,4 +2693,3 @@ After
26212693
})
26222694

26232695
* no longer cache ref
2624-

scripts/publish/changelog.js

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,20 +7,33 @@
77
* (https://www.npmjs.com/package/conventional-changelog), which also prepends
88
* changes to CHANGELOG.md.
99
*
10-
* Runs with default (latest tag...head)
11-
* $ ./changelog.js
10+
* Appends CHANGELOG.md with the changes between tag and HEAD.
11+
* NOTE: only `fix`, `feat`, `perf` and `revert` commits are used
12+
* see: https://github.com/conventional-changelog/conventional-changelog/blob/v0.2.1/presets/angular.js#L24
1213
*/
1314

1415
var fs = require('fs');
1516
var cl = require('conventional-changelog');
17+
const exec = require('child_process').exec;
1618

17-
var changelogStream = fs.createWriteStream('CHANGELOG.md');
19+
var changelogStream = fs.createWriteStream('CHANGELOG-delta.md');
20+
21+
if (process.argv.length < 3) {
22+
console.log('Usage: ./scripts/publish/changelog.js <start-tag>');
23+
process.exit(-1);
24+
}
1825

1926
var config = {
2027
preset: 'angular',
2128
releaseCount: 1,
2229
};
2330

24-
cl(config).on('error', function(err) {
31+
var prependDelta = function() {
32+
exec('cat CHANGELOG-delta.md CHANGELOG.md > CHANGELOG-new.md;' +
33+
'mv CHANGELOG-new.md CHANGELOG.md;'
34+
'rm CHANGELOG-delta.md');
35+
}
36+
37+
cl(config, null, {from: process.argv[2]}).on('error', function(err) {
2538
console.error('Failed to generate changelog: ' + err);
26-
}).pipe(changelogStream);
39+
}).pipe(changelogStream).on('close', prependDelta);

0 commit comments

Comments
 (0)
X Tutup