Skip to content

Commit 7c0d87a

Browse files
chore(*): Release prep - Update CHANGELOG
1 parent a65c58f commit 7c0d87a

File tree

1 file changed

+90
-0
lines changed

1 file changed

+90
-0
lines changed

CHANGELOG.md

+90
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,93 @@
1+
<a name="1.0.0-beta.1"></a>
2+
# [1.0.0-beta.1](https://github.com/angular-ui/ui-router/compare/1.0.0-alpha.5...v1.0.0-beta.1) (2016-06-30)
3+
4+
# UI-Router 1.0 is in beta
5+
6+
## UI-Router has a new home!
7+
8+
https://ui-router.github.io/new-ui-router-site/
9+
10+
11+
# BREAKING CHANGES
12+
13+
These breaking changes are for users upgrading from a previous alpha, not from 0.x legacy series.
14+
This list is extensive, but typical users won't be affected by most of these changes.
15+
16+
The most common breaks will be #1 and #2
17+
18+
1) BC-BREAK: renamed all Ui* (lowercase 'i') symbols to UI* (uppercase 'I') for more consistent naming.
19+
- UiView -> UIView
20+
- UiSref -> UISref (and related directives)
21+
- UiInjector -> UIInjector
22+
23+
2) BC-BREAK: Transition Hooks are no longer injected (onBefore/onStart/onExit/onRetain/onEnter/onFinish/onSuccess/onError)
24+
25+
Previously, a hook like `['$state', ($state) => $state.target('foo')]` would get `$state` injected.
26+
Now, all hooks receive two parameters:
27+
- transition: the current Transition, which has an `injector()` function
28+
- state: for onEnter/onRetain/onExit hooks only, the State which the hook is being run for. This value will be null for onBefore/onStart/onFinish/onSuccess/onError hooks.
29+
30+
Refactor your hooks
31+
from: `['$state', 'mySvc', ($state, mySvc) => mySvc.foo() ? $state.target('foo')] : true`
32+
to: `(trans) => trans.injector().get('mySvc').foo() ? trans.router.stateService.target('foo') : true`
33+
34+
Note: for backwards compatiblity, angular 1 onEnter/onExit/onRetain hooks are still injected
35+
36+
3) BC-BREAK: - The (internal API) State object's .resolve property is now an array of Resolvables, built from your state definitions by the StateBuilder
37+
38+
4) BC-BREAK: - Removed the default resolve called `$resolve$`, which was added in a previous alpha
39+
40+
5) BC-BREAK: - `Transition.addResolves()`  replaced with `Transition.addResolvable()`
41+
42+
6) BC-BREAK: remove `ResolveContext.getResolvables()` in favor of `.getToken()`` and `.getResolvable()`
43+
44+
7) BC-BREAK: remove `ResolveContext.invokeLater()` and `.invokeNow()`
45+
46+
8) BC-BREAK: remove support for `JIT` resolves. This also eliminated the need for the `loadAllControllerLocals` hook which was also removed
47+
48+
9) BC-BREAK: Replaced `ViewConfig.node` with `ViewConfig.path`. Angular 1's `$(element).data('$uiView')` is affected.
49+
Previously the .node was the node for the view. Now the last element in the path is the node for the view.
50+
51+
10) BC-BREAK: Nodes no longer have (stateful) `.resolveContext` properties. Instead, a new ResolveContext is wrapped over a Path of Nodes.  Removed `PathFactory.bindResolveContexts()`.
52+
53+
11) BC-BREAK: ResolveContext.resolvePath returns a promise for resolved data as an array of tuples, instead of a promise for an object of resolved data.  Removed `ResolveContext.resolvePathElement()`.
54+
55+
12) BC-BREAK: Removed ResolvePolicy enum in favor of the ResolvePolicy interface `{ when: "", async: "" }`
56+
57+
13) BC-BREAK: renamed `ResolveContext.isolateRootTo` to `subContext`
58+
59+
14) BC-BREAK: rename `UIRouterGlobals` class to `Globals`; add `UIRouterGlobals` back as an interface
60+
61+
15) BC-BREAK: Moved `defaultErrorHandler` from `TransitionService` to `StateService`
62+
63+
64+
65+
66+
### Features
67+
68+
* **Resolve:** Switch state.resolve to be an array of Resolvables ([6743a60](https://github.com/angular-ui/ui-router/commit/6743a60))
69+
* **Resolve:** support ng2-like provide object literals. Support injection of arbitrary tokens, not just strings. ([a7e5ea6](https://github.com/angular-ui/ui-router/commit/a7e5ea6))
70+
* **Resolve:** support ng2-like provide object literals ([a7e5ea6](https://github.com/angular-ui/ui-router/commit/a7e5ea6))
71+
* **Transition:** expose the current `UiRouter` object as a public property ([52f1308](https://github.com/angular-ui/ui-router/commit/52f1308))
72+
* **redirectTo:** Process `redirectTo` property of a state as a redirect string/object/hook function ([6becb12](https://github.com/angular-ui/ui-router/commit/6becb12)), closes [#27](https://github.com/angular-ui/ui-router/issues/27) [#948](https://github.com/angular-ui/ui-router/issues/948)
73+
* **rejectFactory:** separate transition aborted and transition errored reject types ([55995fd](https://github.com/angular-ui/ui-router/commit/55995fd))
74+
* **ParamType:** allow a custom parameter Type to specify a default value for a parameter's `dynamic` property
75+
* **Resolvable:** Added a new Resolve Policy 'RXWAIT'. If an Observable is returned, pass the observable as the value, but also wait for it to emit its first value
76+
77+
### Bug Fixes
78+
79+
* **ng2.pushState:** Properly match urls when base path set ([b9be2dc](https://github.com/angular-ui/ui-router/commit/b9be2dc)), closes [#2745](https://github.com/angular-ui/ui-router/issues/2745)
80+
* **ng2.UIRouterConfig:** Allow new UIRouter() to finish before configuring it ([a151f71](https://github.com/angular-ui/ui-router/commit/a151f71))
81+
* **ng2.UiView:** fix input resolve binding ([4f53f81](https://github.com/angular-ui/ui-router/commit/4f53f81))
82+
* **ng2.UIView:** Make routed to component appear *inside* UIView, not next to it. ([558fc80](https://github.com/angular-ui/ui-router/commit/558fc80))
83+
* **redirect:** fix bug where redirected transitions with reload: true got wrong resolve values copied ([bd0e3a3](https://github.com/angular-ui/ui-router/commit/bd0e3a3))
84+
* **Rejection:** Silence "Error: Uncaught (in Exception)" ([38432f4](https://github.com/angular-ui/ui-router/commit/38432f4)), closes [#2676](https://github.com/angular-ui/ui-router/issues/2676)
85+
* **Trace:** Fix error in console after $trace.enable() ([013c77a](https://github.com/angular-ui/ui-router/commit/013c77a)), closes [#2752](https://github.com/angular-ui/ui-router/issues/2752)
86+
* **ng2.UIView:** Trigger change detection once for routed components
87+
88+
89+
90+
191
<a name="1.0.0-alpha.5"></a>
292
# [1.0.0-alpha.5](https://github.com/angular-ui/ui-router/compare/1.0.0-alpha.3...v1.0.0-alpha.5) (2016-05-13)
393

0 commit comments

Comments
 (0)