docs: fix links in api docs

This commit is contained in:
Igor Minar 2017-04-25 02:15:33 +02:00 committed by Pete Bacon Darwin
parent 5ba8c14893
commit 71f5b73296
19 changed files with 49 additions and 56 deletions

View File

@ -14,22 +14,18 @@ import {InjectionToken} from '@angular/core';
* `PlatformLocation` encapsulates all calls to DOM apis, which allows the Router to be platform * `PlatformLocation` encapsulates all calls to DOM apis, which allows the Router to be platform
* agnostic. * agnostic.
* This means that we can have different implementation of `PlatformLocation` for the different * This means that we can have different implementation of `PlatformLocation` for the different
* platforms * platforms that angular supports. For example, `@angular/platform-browser` provides an
* that angular supports. For example, the default `PlatformLocation` is {@link * implementation specific to the browser environment, while `@angular/platform-webworker` provides
* BrowserPlatformLocation}, * one suitable for use with web workers.
* however when you run your app in a WebWorker you use {@link WebWorkerPlatformLocation}.
* *
* The `PlatformLocation` class is used directly by all implementations of {@link LocationStrategy} * The `PlatformLocation` class is used directly by all implementations of {@link LocationStrategy}
* when * when they need to interact with the DOM apis like pushState, popState, etc...
* they need to interact with the DOM apis like pushState, popState, etc...
* *
* {@link LocationStrategy} in turn is used by the {@link Location} service which is used directly * {@link LocationStrategy} in turn is used by the {@link Location} service which is used directly
* by * by the {@link Router} in order to navigate between routes. Since all interactions between {@link
* the {@link Router} in order to navigate between routes. Since all interactions between {@link
* Router} / * Router} /
* {@link Location} / {@link LocationStrategy} and DOM apis flow through the `PlatformLocation` * {@link Location} / {@link LocationStrategy} and DOM apis flow through the `PlatformLocation`
* class * class they are all platform independent.
* they are all platform independent.
* *
* @stable * @stable
*/ */

View File

@ -162,8 +162,8 @@ export function getPlatform(): PlatformRef|null {
* has exactly one platform, and services (such as reflection) which are common * has exactly one platform, and services (such as reflection) which are common
* to every Angular application running on the page are bound in its scope. * to every Angular application running on the page are bound in its scope.
* *
* A page's platform is initialized implicitly when {@link bootstrap}() is called, or * A page's platform is initialized implicitly when a platform is created via a platform factory
* explicitly by calling {@link createPlatform}(). * (e.g. {@link platformBrowser}), or explicitly by calling the {@link createPlatform} function.
* *
* @stable * @stable
*/ */
@ -344,8 +344,6 @@ export class PlatformRef_ extends PlatformRef {
/** /**
* A reference to an Angular application running on a page. * A reference to an Angular application running on a page.
* *
* For more about Angular applications, see the documentation for {@link bootstrap}.
*
* @stable * @stable
*/ */
export abstract class ApplicationRef { export abstract class ApplicationRef {

View File

@ -50,7 +50,7 @@ export abstract class Injector {
/** /**
* Retrieves an instance from the injector based on the provided token. * Retrieves an instance from the injector based on the provided token.
* If not found: * If not found:
* - Throws {@link NoProviderError} if no `notFoundValue` that is not equal to * - Throws an error if no `notFoundValue` that is not equal to
* Injector.THROW_IF_NOT_FOUND is given * Injector.THROW_IF_NOT_FOUND is given
* - Returns the `notFoundValue` otherwise * - Returns the `notFoundValue` otherwise
*/ */

View File

@ -54,14 +54,14 @@ export class Compiler {
compileModuleAsync<T>(moduleType: Type<T>): Promise<NgModuleFactory<T>> { throw _throwError(); } compileModuleAsync<T>(moduleType: Type<T>): Promise<NgModuleFactory<T>> { throw _throwError(); }
/** /**
* Same as {@link compileModuleSync} but also creates ComponentFactories for all components. * Same as {@link #compileModuleSync} but also creates ComponentFactories for all components.
*/ */
compileModuleAndAllComponentsSync<T>(moduleType: Type<T>): ModuleWithComponentFactories<T> { compileModuleAndAllComponentsSync<T>(moduleType: Type<T>): ModuleWithComponentFactories<T> {
throw _throwError(); throw _throwError();
} }
/** /**
* Same as {@link compileModuleAsync} but also creates ComponentFactories for all components. * Same as {@link #compileModuleAsync} but also creates ComponentFactories for all components.
*/ */
compileModuleAndAllComponentsAsync<T>(moduleType: Type<T>): compileModuleAndAllComponentsAsync<T>(moduleType: Type<T>):
Promise<ModuleWithComponentFactories<T>> { Promise<ModuleWithComponentFactories<T>> {

View File

@ -16,7 +16,8 @@ import {getSymbolIterator} from '../util';
* An unmodifiable list of items that Angular keeps up to date when the state * An unmodifiable list of items that Angular keeps up to date when the state
* of the application changes. * of the application changes.
* *
* The type of object that {@link Query} and {@link ViewQueryMetadata} provide. * The type of object that {@link ViewChildren}, {@link ContentChildren}, and {@link QueryList}
* provide.
* *
* Implements an iterable interface, therefore it can be used in both ES6 * Implements an iterable interface, therefore it can be used in both ES6
* javascript `for (var i of items)` loops as well as in Angular templates with * javascript `for (var i of items)` loops as well as in Angular templates with

View File

@ -287,7 +287,7 @@ export const ContentChild: ContentChildDecorator = makePropDecorator(
/** /**
* Type of the ViewChildren decorator / constructor function. * Type of the ViewChildren decorator / constructor function.
* *
* See {@ViewChildren}. * See {@link ViewChildren}.
* *
* @stable * @stable
*/ */

View File

@ -662,8 +662,8 @@ export interface Component extends Directive {
* encapsulation. * encapsulation.
* *
* When no `encapsulation` is defined for the component, the default value from the * When no `encapsulation` is defined for the component, the default value from the
* {@link CompilerConfig} is used. The default is `ViewEncapsulation.Emulated`}. Provide a new * {@link CompilerOptions} is used. The default is `ViewEncapsulation.Emulated`}. Provide a new
* `CompilerConfig` to override this value. * `CompilerOptions` to override this value.
* *
* If the encapsulation is set to `ViewEncapsulation.Emulated` and the component has no `styles` * If the encapsulation is set to `ViewEncapsulation.Emulated` and the component has no `styles`
* nor `styleUrls` the encapsulation will automatically be switched to `ViewEncapsulation.None`. * nor `styleUrls` the encapsulation will automatically be switched to `ViewEncapsulation.None`.

View File

@ -9,14 +9,14 @@
/** /**
* Defines template and style encapsulation options available for Component's {@link Component}. * Defines template and style encapsulation options available for Component's {@link Component}.
* *
* See {@link ViewMetadata#encapsulation}. * See {@link Component#encapsulation}.
* @stable * @stable
*/ */
export enum ViewEncapsulation { export enum ViewEncapsulation {
/** /**
* Emulate `Native` scoping of styles by adding an attribute containing surrogate id to the Host * Emulate `Native` scoping of styles by adding an attribute containing surrogate id to the Host
* Element and pre-processing the style rules provided via * Element and pre-processing the style rules provided via
* {@link ViewMetadata#styles} or {@link ViewMetadata#stylesUrls}, and adding the new Host Element * {@link Component#styles} or {@link Component#styleUrls}, and adding the new Host Element
* attribute to all selectors. * attribute to all selectors.
* *
* This is the default option. * This is the default option.

View File

@ -13,8 +13,8 @@ import {EventEmitter} from '../event_emitter';
* *
* The most common use of this service is to optimize performance when starting a work consisting of * The most common use of this service is to optimize performance when starting a work consisting of
* one or more asynchronous tasks that don't require UI updates or error handling to be handled by * one or more asynchronous tasks that don't require UI updates or error handling to be handled by
* Angular. Such tasks can be kicked off via {@link runOutsideAngular} and if needed, these tasks * Angular. Such tasks can be kicked off via {@link #runOutsideAngular} and if needed, these tasks
* can reenter the Angular zone via {@link run}. * can reenter the Angular zone via {@link #run}.
* *
* <!-- TODO: add/fix links to: * <!-- TODO: add/fix links to:
* - docs explaining zones and the use of zones in Angular and change-detection * - docs explaining zones and the use of zones in Angular and change-detection
@ -132,7 +132,7 @@ export class NgZone {
* the function. * the function.
* *
* Running functions via `run` allows you to reenter Angular zone from a task that was executed * Running functions via `run` allows you to reenter Angular zone from a task that was executed
* outside of the Angular zone (typically started via {@link runOutsideAngular}). * outside of the Angular zone (typically started via {@link #runOutsideAngular}).
* *
* Any future tasks or microtasks scheduled from within this function will continue executing from * Any future tasks or microtasks scheduled from within this function will continue executing from
* within the Angular zone. * within the Angular zone.
@ -151,13 +151,14 @@ export class NgZone {
* Executes the `fn` function synchronously in Angular's parent zone and returns value returned by * Executes the `fn` function synchronously in Angular's parent zone and returns value returned by
* the function. * the function.
* *
* Running functions via `runOutsideAngular` allows you to escape Angular's zone and do work that * Running functions via {@link #runOutsideAngular} allows you to escape Angular's zone and do
* work that
* doesn't trigger Angular change-detection or is subject to Angular's error handling. * doesn't trigger Angular change-detection or is subject to Angular's error handling.
* *
* Any future tasks or microtasks scheduled from within this function will continue executing from * Any future tasks or microtasks scheduled from within this function will continue executing from
* outside of the Angular zone. * outside of the Angular zone.
* *
* Use {@link run} to reenter the Angular zone and do work that updates the application model. * Use {@link #run} to reenter the Angular zone and do work that updates the application model.
*/ */
runOutsideAngular(fn: () => any): any { return this.outer.run(fn); } runOutsideAngular(fn: () => any): any { return this.outer.run(fn); }

View File

@ -59,7 +59,7 @@ const resolvedPromise = Promise.resolve(null);
* This directive can be used by itself or as part of a larger form. All you need is the * This directive can be used by itself or as part of a larger form. All you need is the
* `ngModel` selector to activate it. * `ngModel` selector to activate it.
* *
* It accepts a domain model as an optional {@link @Input}. If you have a one-way binding * It accepts a domain model as an optional {@link Input}. If you have a one-way binding
* to `ngModel` with `[]` syntax, changing the value of the domain model in the component * to `ngModel` with `[]` syntax, changing the value of the domain model in the component
* class will set the value in the view. If you have a two-way binding with `[()]` syntax * class will set the value in the view. If you have a two-way binding with `[()]` syntax
* (also known as 'banana-box syntax'), the value in the UI will always be synced back to * (also known as 'banana-box syntax'), the value in the UI will always be synced back to

View File

@ -45,12 +45,12 @@ export const formControlBinding: any = {
* {@link AbstractControl}. * {@link AbstractControl}.
* *
* **Set the value**: You can pass in an initial value when instantiating the {@link FormControl}, * **Set the value**: You can pass in an initial value when instantiating the {@link FormControl},
* or you can set it programmatically later using {@link AbstractControl.setValue} or * or you can set it programmatically later using {@link AbstractControl#setValue} or
* {@link AbstractControl.patchValue}. * {@link AbstractControl#patchValue}.
* *
* **Listen to value**: If you want to listen to changes in the value of the control, you can * **Listen to value**: If you want to listen to changes in the value of the control, you can
* subscribe to the {@link AbstractControl.valueChanges} event. You can also listen to * subscribe to the {@link AbstractControl#valueChanges} event. You can also listen to
* {@link AbstractControl.statusChanges} to be notified when the validation status is * {@link AbstractControl#statusChanges} to be notified when the validation status is
* re-calculated. * re-calculated.
* *
* ### Example * ### Example

View File

@ -45,7 +45,7 @@ export const controlNameBinding: any = {
* closest {@link FormGroup} or {@link FormArray} above it. * closest {@link FormGroup} or {@link FormArray} above it.
* *
* **Access the control**: You can access the {@link FormControl} associated with * **Access the control**: You can access the {@link FormControl} associated with
* this directive by using the {@link AbstractControl.get} method. * this directive by using the {@link AbstractControl#get} method.
* Ex: `this.form.get('first');` * Ex: `this.form.get('first');`
* *
* **Get value**: the `value` property is always synced and available on the {@link FormControl}. * **Get value**: the `value` property is always synced and available on the {@link FormControl}.
@ -53,11 +53,11 @@ export const controlNameBinding: any = {
* *
* **Set value**: You can set an initial value for the control when instantiating the * **Set value**: You can set an initial value for the control when instantiating the
* {@link FormControl}, or you can set it programmatically later using * {@link FormControl}, or you can set it programmatically later using
* {@link AbstractControl.setValue} or {@link AbstractControl.patchValue}. * {@link AbstractControl#setValue} or {@link AbstractControl#patchValue}.
* *
* **Listen to value**: If you want to listen to changes in the value of the control, you can * **Listen to value**: If you want to listen to changes in the value of the control, you can
* subscribe to the {@link AbstractControl.valueChanges} event. You can also listen to * subscribe to the {@link AbstractControl#valueChanges} event. You can also listen to
* {@link AbstractControl.statusChanges} to be notified when the validation status is * {@link AbstractControl#statusChanges} to be notified when the validation status is
* re-calculated. * re-calculated.
* *
* ### Example * ### Example

View File

@ -34,11 +34,11 @@ export const formDirectiveProvider: any = {
* *
* **Set value**: You can set the form's initial value when instantiating the * **Set value**: You can set the form's initial value when instantiating the
* {@link FormGroup}, or you can set it programmatically later using the {@link FormGroup}'s * {@link FormGroup}, or you can set it programmatically later using the {@link FormGroup}'s
* {@link AbstractControl.setValue} or {@link AbstractControl.patchValue} methods. * {@link AbstractControl#setValue} or {@link AbstractControl#patchValue} methods.
* *
* **Listen to value**: If you want to listen to changes in the value of the form, you can subscribe * **Listen to value**: If you want to listen to changes in the value of the form, you can subscribe
* to the {@link FormGroup}'s {@link AbstractControl.valueChanges} event. You can also listen to * to the {@link FormGroup}'s {@link AbstractControl#valueChanges} event. You can also listen to
* its {@link AbstractControl.statusChanges} event to be notified when the validation status is * its {@link AbstractControl#statusChanges} event to be notified when the validation status is
* re-calculated. * re-calculated.
* *
* Furthermore, you can listen to the directive's `ngSubmit` event to be notified when the user has * Furthermore, you can listen to the directive's `ngSubmit` event to be notified when the user has

View File

@ -40,7 +40,7 @@ export const formGroupNameProvider: any = {
* controls into their own nested object. * controls into their own nested object.
* *
* **Access the group**: You can access the associated {@link FormGroup} using the * **Access the group**: You can access the associated {@link FormGroup} using the
* {@link AbstractControl.get} method. Ex: `this.form.get('name')`. * {@link AbstractControl#get} method. Ex: `this.form.get('name')`.
* *
* You can also access individual controls within the group using dot syntax. * You can also access individual controls within the group using dot syntax.
* Ex: `this.form.get('name.first')` * Ex: `this.form.get('name.first')`
@ -50,11 +50,11 @@ export const formGroupNameProvider: any = {
* *
* **Set the value**: You can set an initial value for each child control when instantiating * **Set the value**: You can set an initial value for each child control when instantiating
* the {@link FormGroup}, or you can set it programmatically later using * the {@link FormGroup}, or you can set it programmatically later using
* {@link AbstractControl.setValue} or {@link AbstractControl.patchValue}. * {@link AbstractControl#setValue} or {@link AbstractControl#patchValue}.
* *
* **Listen to value**: If you want to listen to changes in the value of the group, you can * **Listen to value**: If you want to listen to changes in the value of the group, you can
* subscribe to the {@link AbstractControl.valueChanges} event. You can also listen to * subscribe to the {@link AbstractControl#valueChanges} event. You can also listen to
* {@link AbstractControl.statusChanges} to be notified when the validation status is * {@link AbstractControl#statusChanges} to be notified when the validation status is
* re-calculated. * re-calculated.
* *
* ### Example * ### Example
@ -111,7 +111,7 @@ export const formArrayNameProvider: any = {
* form controls dynamically. * form controls dynamically.
* *
* **Access the array**: You can access the associated {@link FormArray} using the * **Access the array**: You can access the associated {@link FormArray} using the
* {@link AbstractControl.get} method on the parent {@link FormGroup}. * {@link AbstractControl#get} method on the parent {@link FormGroup}.
* Ex: `this.form.get('cities')`. * Ex: `this.form.get('cities')`.
* *
* **Get the value**: the `value` property is always synced and available on the * **Get the value**: the `value` property is always synced and available on the
@ -119,12 +119,12 @@ export const formArrayNameProvider: any = {
* *
* **Set the value**: You can set an initial value for each child control when instantiating * **Set the value**: You can set an initial value for each child control when instantiating
* the {@link FormArray}, or you can set the value programmatically later using the * the {@link FormArray}, or you can set the value programmatically later using the
* {@link FormArray}'s {@link AbstractControl.setValue} or {@link AbstractControl.patchValue} * {@link FormArray}'s {@link AbstractControl#setValue} or {@link AbstractControl#patchValue}
* methods. * methods.
* *
* **Listen to value**: If you want to listen to changes in the value of the array, you can * **Listen to value**: If you want to listen to changes in the value of the array, you can
* subscribe to the {@link FormArray}'s {@link AbstractControl.valueChanges} event. You can also * subscribe to the {@link FormArray}'s {@link AbstractControl#valueChanges} event. You can also
* listen to its {@link AbstractControl.statusChanges} event to be notified when the validation * listen to its {@link AbstractControl#statusChanges} event to be notified when the validation
* status is re-calculated. * status is re-calculated.
* *
* **Add new controls**: You can add new controls to the {@link FormArray} dynamically by * **Add new controls**: You can add new controls to the {@link FormArray} dynamically by

View File

@ -886,7 +886,7 @@ export class FormGroup extends AbstractControl {
* Check whether there is an enabled control with the given name in the group. * Check whether there is an enabled control with the given name in the group.
* *
* It will return false for disabled controls. If you'd like to check for * It will return false for disabled controls. If you'd like to check for
* existence in the group only, use {@link AbstractControl.get} instead. * existence in the group only, use {@link AbstractControl#get} instead.
*/ */
contains(controlName: string): boolean { contains(controlName: string): boolean {
return this.controls.hasOwnProperty(controlName) && this.controls[controlName].enabled; return this.controls.hasOwnProperty(controlName) && this.controls[controlName].enabled;

View File

@ -24,9 +24,6 @@ function isEmptyInputValue(value: any): boolean {
* *
* Provide this using `multi: true` to add validators. * Provide this using `multi: true` to add validators.
* *
* ### Example
*
* {@example core/forms/ts/ng_validators/ng_validators.ts region='ng_validators'}
* @stable * @stable
*/ */
export const NG_VALIDATORS = new InjectionToken<Array<Validator|Function>>('NgValidators'); export const NG_VALIDATORS = new InjectionToken<Array<Validator|Function>>('NgValidators');

View File

@ -13,8 +13,9 @@ import {WebWorkerPlatformLocation} from './platform_location';
/** /**
* Those providers should be added when the router is used in a worker context in addition to the * The {@link PlatformLocation} providers that should be added when the {@link Location} is used in
* {@link ROUTER_PROVIDERS} and after them. * a worker context.
*
* @experimental * @experimental
*/ */
export const WORKER_APP_LOCATION_PROVIDERS = [ export const WORKER_APP_LOCATION_PROVIDERS = [

View File

@ -20,7 +20,6 @@ import {UrlSegment, UrlSegmentGroup} from './url_tree';
* - `path` is a string that uses the route matcher DSL. * - `path` is a string that uses the route matcher DSL.
* - `pathMatch` is a string that specifies the matching strategy. * - `pathMatch` is a string that specifies the matching strategy.
* - `matcher` defines a custom strategy for path matching and supersedes `path` and `pathMatch`. * - `matcher` defines a custom strategy for path matching and supersedes `path` and `pathMatch`.
* See {@link UrlMatcher} for more info.
* - `component` is a component type. * - `component` is a component type.
* - `redirectTo` is the url fragment which will replace the current matched segment. * - `redirectTo` is the url fragment which will replace the current matched segment.
* - `outlet` is the name of the outlet the component should be placed into. * - `outlet` is the name of the outlet the component should be placed into.

View File

@ -92,7 +92,7 @@ export class RouterOutlet implements OnDestroy {
} }
} }
/** @deprecated since v4, use {@link activateWith} */ /** @deprecated since v4, use {@link #activateWith} */
activate( activate(
activatedRoute: ActivatedRoute, resolver: ComponentFactoryResolver, injector: Injector, activatedRoute: ActivatedRoute, resolver: ComponentFactoryResolver, injector: Injector,
providers: ResolvedReflectiveProvider[], outletMap: RouterOutletMap): void { providers: ResolvedReflectiveProvider[], outletMap: RouterOutletMap): void {