Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit c10dba1

Browse files
Narretzpetebacondarwin
authored andcommitted
docs(ngComponentRouter): add deprecation notice and better install notes
Yes, that contradicts itself. Closes #14655 Closes #14717
1 parent f05ffd9 commit c10dba1

File tree

2 files changed

+33
-1
lines changed

2 files changed

+33
-1
lines changed

Diff for: docs/content/guide/component-router.ngdoc

+13
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@
55

66
# Component Router
77

8+
<div class="alert alert-danger">
9+
**Deprecation Notice:** This implementation of the Component Router (ngComponentRouter module) has been deprecated and will not receive further updates.
10+
Alternatively, use the {@link ngRoute} module or community developed projects (e.g. [ui-router](https://github.com/angular-ui/ui-router)).
11+
</div>
12+
813
This guide describes the new Component Router for AngularJS 1.5.
914

1015
<div class="alert alert-info">
@@ -482,6 +487,14 @@ Just like any Angular application, we load the JavaScript files into our `index.
482487
<script src="/app/app.js"></script>
483488
```
484489

490+
You also need to include ES6 shims for browsers that do not support ES6 code (Internet Explorer,
491+
iOs < 8, Android < 5.0, Windows Mobile < 10):
492+
```html
493+
<!-- IE required polyfills, in this exact order -->
494+
<script src="https://cdnjs.cloudflare.com/ajax/libs/es6-shim/0.33.3/es6-shim.min.js"></script>
495+
<script src="https://cdnjs.cloudflare.com/ajax/libs/systemjs/0.19.20/system-polyfills.js"></script>
496+
<script src="https://npmcdn.com/angular2/es6/dev/src/testing/shims_for_IE.js"></script>
497+
```
485498

486499
## Create the `app` module
487500

Diff for: src/ngComponentRouter/Router.js

+20-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,11 @@
33
* @name ngComponentRouter
44
* @installation
55
*
6+
* <div class="alert alert-danger">
7+
* **Deprecation Notice:** This implementation of the Component Router has been deprecated and will not receive further updates.
8+
* Alternatively, use the {@link ngRoute} module or community developed projects (e.g. [ui-router](https://github.com/angular-ui/ui-router)).
9+
* </div>
10+
611
* Currently, the **Component Router** module must be installed via `npm`, it is not yet available
712
* on Bower or the Google CDN.
813
*
@@ -15,7 +20,8 @@
1520
* <script src="/node_modules/@angular/router/angular1/angular_1_router.js"></script>
1621
*```
1722
*
18-
* You also need to include ES6 shims to support running on Internet Explorer:
23+
* You also need to include ES6 shims for browsers that do not support ES6 code (Internet Explorer,
24+
iOs < 8, Android < 5.0, Windows Mobile < 10):
1925
* ```html
2026
* <!-- IE required polyfills, in this exact order -->
2127
* <script src="https://cdnjs.cloudflare.com/ajax/libs/es6-shim/0.33.3/es6-shim.min.js"></script>
@@ -36,6 +42,7 @@
3642
* @ngdoc type
3743
* @name Router
3844
* @description
45+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
3946
* A `Router` is responsible for mapping URLs to components.
4047
*
4148
* * Routers and "Routing Component" instances have a 1:1 correspondence.
@@ -51,6 +58,7 @@
5158
* @ngdoc type
5259
* @name ChildRouter
5360
* @description
61+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
5462
*
5563
* This type extends the {@link Router}.
5664
*
@@ -63,6 +71,7 @@
6371
* @ngdoc type
6472
* @name RootRouter
6573
* @description
74+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
6675
*
6776
* This type extends the {@link Router}.
6877
*
@@ -75,6 +84,8 @@
7584
* @ngdoc type
7685
* @name ComponentInstruction
7786
* @description
87+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
88+
*
7889
* A `ComponentInstruction` represents the route state for a single component. An `Instruction` is
7990
* composed of a tree of these `ComponentInstruction`s.
8091
*
@@ -88,6 +99,7 @@
8899
* @ngdoc type
89100
* @name RouteDefinition
90101
* @description
102+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
91103
*
92104
* Each item in the **RouteConfig** for a **Routing Component** is an instance of
93105
* this type. It can have the following properties:
@@ -102,6 +114,8 @@
102114
* @ngdoc type
103115
* @name RouteParams
104116
* @description
117+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
118+
*
105119
* A map of parameters for a given route, passed as part of the {@link ComponentInstruction} to
106120
* the Lifecycle Hooks, such as `$routerOnActivate` and `$routerOnDeactivate`.
107121
*/
@@ -112,13 +126,15 @@
112126
* @priority 400
113127
* restrict: AE
114128
* @description
129+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
115130
*
116131
* The directive that identifies where the {@link Router} should render its **Components**.
117132
*/
118133

119134
/**
120135
* @name ngLink
121136
* @description
137+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
122138
*
123139
* Lets you create links to different views, automatically generating the `href`.
124140
*
@@ -135,6 +151,8 @@
135151
* @ngdoc service
136152
* @name $rootRouter
137153
* @description
154+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
155+
*
138156
* The singleton instance of the {@link RootRouter} type, which is associated
139157
* with the top level {@link $routerRootComponent}.
140158
*/
@@ -144,6 +162,7 @@
144162
* @ngdoc service
145163
* @name $routerRootComponent
146164
* @description
165+
* @deprecated This implementation of the Component Router has been deprecated and should not be used anymore.
147166
*
148167
* The top level **Routing Component** associated with the {@link $rootRouter}.
149168
*/

0 commit comments

Comments
 (0)