Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit acbd7cd

Browse files
vojtajinamhevery
authored andcommitted
style(docs): make jslint happy - fix some warnings
1 parent 035c751 commit acbd7cd

File tree

103 files changed

+569
-573
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+569
-573
lines changed

docs/content/api/angular.module.NG.ngdoc

Lines changed: 0 additions & 5 deletions
This file was deleted.

docs/content/api/angular.module.ngdoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ function MyModule($provide, $locationProvider){
2525
};
2626
</pre>
2727

28-
See: {@link angular.module.AUTO.$provide $provide}, {@link angular.module.NG.$locationProvider $locationProvider}.
28+
See: {@link angular.module.AUTO.$provide $provide}, {@link angular.module.ng.$locationProvider $locationProvider}.
2929

3030
# Registering Module Function
3131

@@ -44,11 +44,11 @@ angular.module.MyModule = function(){
4444
Then you can refer to your module like this:
4545

4646
<pre>
47-
var injector = angular.injector('NG', 'MyModule')
47+
var injector = angular.injector('ng', 'MyModule')
4848
</pre>
4949

5050
Or
5151

5252
<pre>
53-
var injector = angular.injector('NG', angular.module.MyModule)
53+
var injector = angular.injector('ng', angular.module.MyModule)
5454
</pre>

docs/content/api/index.ngdoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,23 @@
77
* {@link angular.widget Widgets} - Angular custom DOM element
88
* {@link angular.directive Directives} - Angular DOM element attributes
99
* {@link angular.markup Markup} and {@link angular.attrMarkup Attribute Markup}
10-
* {@link angular.module.NG.$filter Filters} - Angular output filters
11-
* {@link angular.module.NG.$compile $compile} - Template compiler
10+
* {@link angular.module.ng.$filter Filters} - Angular output filters
11+
* {@link angular.module.ng.$compile $compile} - Template compiler
1212

1313
## Angular Scope API
1414

15-
* {@link angular.module.NG.$rootScope.Scope Scope Object} - Angular scope object
15+
* {@link angular.module.ng.$rootScope.Scope Scope Object} - Angular scope object
1616

1717

1818
## Angular Services & Dependency Injection API
1919

20-
* {@link angular.module.NG Angular Services}
20+
* {@link angular.module.ng Angular Services}
2121
* {@link angular.injector angular.injector() }
2222

2323

2424
## Angular Testing API
2525

26-
* {@link angular.module.NG_MOCK Testing Mocks API} - Mock objects for testing
26+
* {@link angular.module.ngMock Testing Mocks API} - Mock objects for testing
2727
* {@link guide/dev_guide.e2e-testing Angular Scenario Runner} - Automated scenario testing
2828
documentation
2929

docs/content/cookbook/deeplinking.ngdoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,9 +105,9 @@ The two partials are defined in the following URLs:
105105
# Things to notice
106106

107107
* Routes are defined in the `AppCntl` class. The initialization of the controller causes the
108-
initialization of the {@link api/angular.module.NG.$route $route} service with the proper URL
108+
initialization of the {@link api/angular.module.ng.$route $route} service with the proper URL
109109
routes.
110-
* The {@link api/angular.module.NG.$route $route} service then watches the URL and instantiates the
110+
* The {@link api/angular.module.ng.$route $route} service then watches the URL and instantiates the
111111
appropriate controller when the URL changes.
112112
* The {@link api/angular.widget.ng:view ng:view} widget loads the view when the URL changes. It
113113
also

docs/content/cookbook/form.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ allow a user to enter data.
104104

105105
* The user data model is initialized {@link api/angular.directive.ng:controller controller} and is
106106
available in
107-
the {@link api/angular.module.NG.$rootScope.Scope scope} with the initial data.
107+
the {@link api/angular.module.ng.$rootScope.Scope scope} with the initial data.
108108
* For debugging purposes we have included a debug view of the model to better understand what
109109
is going on.
110110
* The {@link api/angular.widget.input input widgets} simply refer to the model and are data-bound.

docs/content/cookbook/helloworld.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Take a look through the source and note:
3131
* The script tag that {@link guide/dev_guide.bootstrap bootstraps} the angular environment.
3232
* The text {@link api/angular.widget.input input widget} which is bound to the greeting name text.
3333
* No need for listener registration and event firing on change events.
34-
* The implicit presence of the `name` variable which is in the root {@link api/angular.module.NG.$rootScope.Scope scope}.
34+
* The implicit presence of the `name` variable which is in the root {@link api/angular.module.ng.$rootScope.Scope scope}.
3535
* The double curly brace `{{markup}}`, which binds the name variable to the greeting text.
3636
* The concept of {@link guide/dev_guide.templates.databinding data binding}, which reflects any
3737
changes to the

docs/content/cookbook/index.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ allowing you to send links to specific screens in your app.
4444

4545
# Services
4646

47-
{@link api/angular.module.NG Services}: Services are long lived objects in your applications that are
47+
{@link api/angular.module.ng Services}: Services are long lived objects in your applications that are
4848
available across controllers. A collection of useful services are pre-bundled with angular but you
4949
will likely add your own. Services are initialized using dependency injection, which resolves the
5050
order of initialization. This safeguards you from the perils of global state (a common way to

docs/content/cookbook/mvc.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,4 +121,4 @@ board variable.
121121
* The view can call any controller function.
122122
* In this example, the `setUrl()` and `readUrl()` functions copy the game state to/from the URL's
123123
hash so the browser's back button will undo game steps. See deep-linking. This example calls {@link
124-
api/angular.module.NG.$rootScope.Scope#$watch $watch()} to set up a listener that invokes `readUrl()` when needed.
124+
api/angular.module.ng.$rootScope.Scope#$watch $watch()} to set up a listener that invokes `readUrl()` when needed.

docs/content/guide/dev_guide.bootstrap.auto_bootstrap.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,4 +98,4 @@ APIs are bound to fields of this global object.
9898

9999
## Related API
100100

101-
{@link api/angular.module.NG.$compile Compiler API}
101+
{@link api/angular.module.ng.$compile Compiler API}

docs/content/guide/dev_guide.bootstrap.manual_bootstrap.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,4 @@ an executable, bi-directionally bound application.
4343

4444
## Related API
4545

46-
{@link api/angular.module.NG.$compile Compiler API}
46+
{@link api/angular.module.ng.$compile Compiler API}

docs/content/guide/dev_guide.compiler.directives.creating_directives.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ angular.directive('ng:bind', function(expression, compiledElement) {
2323
The angular compiler exposes methods that you may need to use when writing your own widgets and
2424
directives. For example, the `descend()` method lets you control whether the compiler ignores or
2525
processes child elements of the element it is compiling. For information on this and other
26-
compiler methods, see the {@link api/angular.module.NG.$compile Compiler API doc}.
26+
compiler methods, see the {@link api/angular.module.ng.$compile Compiler API doc}.
2727

2828

2929
## Related Docs

docs/content/guide/dev_guide.compiler.extending_compiler.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,4 +93,4 @@ corresponding spans.
9393

9494
## Related API
9595

96-
* {@link api/angular.module.NG.$compile $compile()}
96+
* {@link api/angular.module.ng.$compile $compile()}

docs/content/guide/dev_guide.compiler.markup.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,4 +89,4 @@ angular.attrMarkup('extraClass', function(attrValue, attrName, element){
8989

9090
## Related API
9191

92-
* {@link api/angular.module.NG.$compile Compiler API Reference}
92+
* {@link api/angular.module.ng.$compile Compiler API Reference}

docs/content/guide/dev_guide.compiler.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,4 @@ All compilation takes place in the web browser; no server is involved.
2323

2424
## Related API
2525

26-
* {@link api/angular.module.NG.$compile Angular Compiler API}
26+
* {@link api/angular.module.ng.$compile Angular Compiler API}

docs/content/guide/dev_guide.compiler.testing_dom_element.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@
1414

1515
## Related API
1616

17-
* {@link api/angular.module.NG.$compile $compile()}
17+
* {@link api/angular.module.ng.$compile $compile()}

docs/content/guide/dev_guide.compiler.understanding_compiler.ngdoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ dataset]"`), the link function gets called to set up a listener on each element
2020

2121
Note that angular's built-in widgets, directives, and markup have predefined compile and link
2222
functions that you don't need to modify. When you create your own widgets, directives, or markup,
23-
you must write compile and link functions for them. Refer to the {@link api/angular.module.NG.$compile
23+
you must write compile and link functions for them. Refer to the {@link api/angular.module.ng.$compile
2424
Compiler API} for details.
2525

2626
When the angular compiler compiles a page, it proceeds through 3 phases: Compile, Create Root
@@ -53,7 +53,7 @@ Note that while the compile function is executed exactly once, the link function
5353
multiple times, for example, once for each iteration in a repeater.
5454

5555
The angular compiler exposes methods that you will need to make use of when writing your own
56-
widgets and directives. For information on these methods, see the {@link api/angular.module.NG.$compile
56+
widgets and directives. For information on these methods, see the {@link api/angular.module.ng.$compile
5757
Compiler API doc}.
5858

5959

@@ -65,4 +65,4 @@ Compiler API doc}.
6565

6666
## Related API
6767

68-
* {@link api/angular.module.NG.$compile $compile()}
68+
* {@link api/angular.module.ng.$compile $compile()}

docs/content/guide/dev_guide.compiler.widgets.creating_widgets.ngdoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ angular.widget('my:time', function(compileElement){
8080
The angular compiler exposes methods that you may need to use of when writing your own widgets and
8181
directives. For example, the `descend()` method lets you control whether the compiler ignores or
8282
processes child elements of the element it is compiling. For information on this and other
83-
compiler methods, see the {@link api/angular.module.NG.$compile Compiler API doc}.
83+
compiler methods, see the {@link api/angular.module.ng.$compile Compiler API doc}.
8484

8585

8686
## Related Topics
@@ -92,4 +92,4 @@ compiler methods, see the {@link api/angular.module.NG.$compile Compiler API doc
9292

9393
## Related API
9494

95-
* {@link api/angular.module.NG.$compile Compiler API}
95+
* {@link api/angular.module.ng.$compile Compiler API}

docs/content/guide/dev_guide.compiler.widgets.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,4 @@ dev_guide.compiler.widgets.creating_widgets Creating Custom Widgets}.
3232

3333
## Related API
3434

35-
* {@link api/angular.module.NG.$compile Compiler API}
35+
* {@link api/angular.module.ng.$compile Compiler API}

docs/content/guide/dev_guide.di.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,5 @@ book.
2828

2929
## Related API
3030

31-
* {@link api/angular.module.NG Service API}
31+
* {@link api/angular.module.ng Service API}
3232
* {@link api/angular.injector Angular Injector API}

docs/content/guide/dev_guide.di.understanding_di.ngdoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@ While DI is widely used in statically typed languages such as Java or C++, it ha
77
used in JavaScript. Angular brings the benefits of DI into JavaScript apps.
88

99
In angular, DI is implemented as a subsystem that manages dependencies between services,
10-
controllers, widgets, and filters. The most important of these are {@link api/angular.module.NG
10+
controllers, widgets, and filters. The most important of these are {@link api/angular.module.ng
1111
services}.
1212

1313
Services are objects that handle common tasks in web applications. Angular provides several{@link
14-
api/angular.module.NG built-in services}, and you can create your own custom services.
14+
api/angular.module.ng built-in services}, and you can create your own custom services.
1515

1616
The main job of angular's DI subsystem is to provide services to angular components that depend on
1717
them. The way the DI subsystem provides services is as follows: all services are registered with
18-
angular's {@link api/angular.module.NG service API}, and all components that depend on services
18+
angular's {@link api/angular.module.ng service API}, and all components that depend on services
1919
define those dependencies as a property (`$inject`). With this information, the DI subsystem
2020
manages the creation of service objects and the provision of those objects to the components that
2121
need them, at the time they need them. The following illustration steps through the sequence of
@@ -49,7 +49,7 @@ achieve the necessary isolation by having each test create its own separate root
4949

5050
<pre>
5151
// create a root scope
52-
var rootScope = angular.module.NG.$rootScope.Scope();
52+
var rootScope = angular.module.ng.$rootScope.Scope();
5353
// access the service locator
5454
var myService = rootScope.$service('myService');
5555
</pre>
@@ -74,7 +74,7 @@ equivalent:
7474

7575
<pre>
7676
// given a user defined service
77-
angular.module.NG('serviceA', ...);
77+
angular.module.ng('serviceA', ...);
7878

7979
// inject '$window', 'serviceA', curry 'name';
8080
function fnA($window, serviceA, name){};
@@ -102,4 +102,4 @@ code and insert the `$inject` into the source code so that it can be minified/ob
102102

103103
## Related API
104104

105-
* {@link api/angular.module.NG Services API}
105+
* {@link api/angular.module.ng Services API}

docs/content/guide/dev_guide.di.using_di_controllers.ngdoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ MyController.$inject = ['$route'];
1414
</pre>
1515

1616
In this example, the `MyController` constructor function takes one argument, the {@link
17-
api/angular.module.NG.$route $route} service. Angular is then responsible for supplying the instance
17+
api/angular.module.ng.$route $route} service. Angular is then responsible for supplying the instance
1818
of `$route` to the controller when the constructor is instantiated. There are two ways to cause
1919
controller instantiation – by configuring routes with the `$route` service, or by referencing the
2020
controller from the HTML template, as follows:

docs/content/guide/dev_guide.e2e-testing.ngdoc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,19 +78,19 @@ Returns the window.location.search of the currently loaded page in the test fram
7878
Returns the window.location.hash (without `#`) of the currently loaded page in the test frame.
7979

8080
## browser().location().url()
81-
Returns the {@link api/angular.module.NG.$location $location.url()} of the currently loaded page in
81+
Returns the {@link api/angular.module.ng.$location $location.url()} of the currently loaded page in
8282
the test frame.
8383

8484
## browser().location().path()
85-
Returns the {@link api/angular.module.NG.$location $location.path()} of the currently loaded page in
85+
Returns the {@link api/angular.module.ng.$location $location.path()} of the currently loaded page in
8686
the test frame.
8787

8888
## browser().location().search()
89-
Returns the {@link api/angular.module.NG.$location $location.search()} of the currently loaded page
89+
Returns the {@link api/angular.module.ng.$location $location.search()} of the currently loaded page
9090
in the test frame.
9191

9292
## browser().location().hash()
93-
Returns the {@link api/angular.module.NG.$location $location.hash()} of the currently loaded page in
93+
Returns the {@link api/angular.module.ng.$location $location.hash()} of the currently loaded page in
9494
the test frame.
9595

9696
## expect(future).{matcher}

docs/content/guide/dev_guide.expressions.ngdoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -165,15 +165,15 @@ JavaScript method instead.
165165
Built-in types have methods like `[].push()`, but the richness of these methods is limited.
166166
Consider the example below, which allows you to do a simple search over a canned set of contacts.
167167
The example would be much more complicated if we did not have the `Array:$filter()`. There is no
168-
built-in method on `Array` called {@link api/angular.module.NG.$filter.filter $filter} and angular doesn't add
168+
built-in method on `Array` called {@link api/angular.module.ng.$filter.filter $filter} and angular doesn't add
169169
it to `Array.prototype` because that could collide with other JavaScript frameworks.
170170

171171
For this reason the scope expression evaluator augments the built-in types to make them act like
172-
they have extra methods. The actual method for `$filter()` is `angular.module.NG.$filter.filter()`. You can
172+
they have extra methods. The actual method for `$filter()` is `angular.module.ng.$filter.filter()`. You can
173173
call it from JavaScript.
174174

175175
Extensions: You can further extend the expression vocabulary by adding new methods to
176-
`angular.module.NG.$filter` or `angular.String`, etc.
176+
`angular.module.ng.$filter` or `angular.String`, etc.
177177

178178
<doc:example>
179179
<doc:source>
@@ -212,7 +212,7 @@ of filters like this:
212212

213213
name | uppercase
214214

215-
The expression evaluator simply passes the value of name to angular.module.NG.$filter.uppercase.
215+
The expression evaluator simply passes the value of name to angular.module.ng.$filter.uppercase.
216216

217217
Chain filters using this syntax:
218218

@@ -243,4 +243,4 @@ so that angular developers and developers who use angular can develop in harmony
243243

244244
## Related API
245245

246-
* {@link api/angular.module.NG.$compile Angular Compiler API}
246+
* {@link api/angular.module.ng.$compile Angular Compiler API}

docs/content/guide/dev_guide.forms.ngdoc

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@ Forms consist of all of the following:
1818

1919
A form groups a set of widgets together into a single logical data-set. A form is created using
2020
the {@link api/angular.widget.form &lt;form&gt;} element that calls the
21-
{@link api/angular.module.NG.$formFactory $formFactory} service. The form is responsible for managing
21+
{@link api/angular.module.ng.$formFactory $formFactory} service. The form is responsible for managing
2222
the widgets and for tracking validation information.
2323

2424
A form is:
2525

2626
- The collection which contains widgets or other forms.
2727
- Responsible for marshaling data from the model into a widget. This is
28-
triggered by {@link api/angular.module.NG.$rootScope.Scope#$watch $watch} of the model expression.
28+
triggered by {@link api/angular.module.ng.$rootScope.Scope#$watch $watch} of the model expression.
2929
- Responsible for marshaling data from the widget into the model. This is
3030
triggered by the widget emitting the `$viewChange` event.
3131
- Responsible for updating the validation state of the widget, when the widget emits
@@ -57,7 +57,7 @@ In Angular, a widget is the term used for the UI with which the user input. Exam
5757
bult-in Angular widgets are {@link api/angular.widget.input input} and
5858
{@link api/angular.widget.select select}. Widgets provide the rendering and the user
5959
interaction logic. Widgets should be declared inside a form, if no form is provided an implicit
60-
form {@link api/angular.module.NG.$formFactory $formFactory.rootForm} form is used.
60+
form {@link api/angular.module.ng.$formFactory $formFactory.rootForm} form is used.
6161

6262
Widgets are implemented as Angular controllers. A widget controller:
6363

@@ -218,7 +218,7 @@ The following example demonstrates:
218218
# Life-cycle
219219

220220
- The `<form>` element triggers creation of a new form {@link dev_guide.scopes scope} using the
221-
{@link api/angular.module.NG.$formFactory $formfactory}. The new form scope is added to the
221+
{@link api/angular.module.ng.$formFactory $formfactory}. The new form scope is added to the
222222
`<form>` element using the jQuery `.data()` method for later retrieval under the key `$form`.
223223
The form also sets up these listeners:
224224

@@ -227,8 +227,8 @@ The following example demonstrates:
227227
- `$valid` / `$invalid` - This event is emitted by the widget on validation state change.
228228

229229
- `<input>` element triggers the creation of the widget using the
230-
{@link api/angular.module.NG.$formFactory $formfactory.$createWidget()} method. The `$createWidget()`
231-
creates new widget instance by calling the current scope {@link api/angular.module.NG.$rootScope.Scope#$new .$new()} and
230+
{@link api/angular.module.ng.$formFactory $formfactory.$createWidget()} method. The `$createWidget()`
231+
creates new widget instance by calling the current scope {@link api/angular.module.ng.$rootScope.Scope#$new .$new()} and
232232
registers these listeners:
233233

234234
- `$watch` on the model scope.
@@ -244,7 +244,7 @@ The following example demonstrates:
244244
1. The DOM element fires the `change` event which the widget intercepts. Widget then emits
245245
a `$viewChange` event which includes the new user-entered value. (Remember that the DOM events
246246
are outside of the Angular environment so the widget must emit its event within the
247-
{@link api/angular.module.NG.$rootScope.Scope#$apply $apply} method).
247+
{@link api/angular.module.ng.$rootScope.Scope#$apply $apply} method).
248248
2. The form's `$viewChange` listener copies the user-entered value to the widget's `$viewValue`
249249
property. Since the `$viewValue` is the raw value as entered by user, it may need to be
250250
translated to a different format/type (for example, translating a string to a number).
@@ -517,7 +517,7 @@ function LoginController() {
517517

518518
describe('LoginController', function() {
519519
it('should disable login button when form is invalid', function() {
520-
var scope = angular.module.NG.$rootScope.Scope();
520+
var scope = angular.module.ng.$rootScope.Scope();
521521
var loginController = scope.$new(LoginController);
522522

523523
// In production the 'loginForm' form instance gets set from the view,
@@ -570,7 +570,7 @@ function LoginController(){
570570

571571
describe('LoginController', function() {
572572
it('should disable login button when form is invalid', function() {
573-
var scope = angular.module.NG.$rootScope.Scope();
573+
var scope = angular.module.ng.$rootScope.Scope();
574574
var loginController = scope.$new(LoginController);
575575
var input = angular.element('<input>');
576576

0 commit comments

Comments
 (0)