diff --git a/packages/upgrade/src/common/downgrade_component.ts b/packages/upgrade/src/common/downgrade_component.ts index f536ca235b..ed2edc58bb 100644 --- a/packages/upgrade/src/common/downgrade_component.ts +++ b/packages/upgrade/src/common/downgrade_component.ts @@ -29,6 +29,7 @@ interface Thenable { * This helper function returns a factory function to be used for registering * an AngularJS wrapper directive for "downgrading" an Angular component. * + * @usageNotes * ### Examples * * Let's assume that you have an Angular component called `ng2Heroes` that needs diff --git a/packages/upgrade/src/common/downgrade_injectable.ts b/packages/upgrade/src/common/downgrade_injectable.ts index c763067eb2..9c35a82f83 100644 --- a/packages/upgrade/src/common/downgrade_injectable.ts +++ b/packages/upgrade/src/common/downgrade_injectable.ts @@ -20,6 +20,7 @@ import {INJECTOR_KEY} from './constants'; * This helper function returns a factory function that provides access to the Angular * service identified by the `token` parameter. * + * @usageNotes * ### Examples * * First ensure that the service to be downgraded is provided in an `NgModule` diff --git a/packages/upgrade/src/dynamic/upgrade_adapter.ts b/packages/upgrade/src/dynamic/upgrade_adapter.ts index cc16325dc1..32c3d39c55 100644 --- a/packages/upgrade/src/dynamic/upgrade_adapter.ts +++ b/packages/upgrade/src/dynamic/upgrade_adapter.ts @@ -30,7 +30,8 @@ let upgradeCount: number = 0; * 3. Bootstrapping of a hybrid Angular application which contains both of the frameworks * coexisting in a single application. * - * ## Mental Model + * @usageNotes + * ### Mental Model * * When reasoning about how a hybrid application works it is useful to have a mental model which * describes what is happening and explains what is happening at the lowest level. @@ -134,7 +135,8 @@ export class UpgradeAdapter { * Angular Component. The adapter will bootstrap Angular component from within the * AngularJS template. * - * ## Mental Model + * @usageNotes + * ### Mental Model * * 1. The component is instantiated by being listed in AngularJS template. This means that the * host element is controlled by AngularJS, but the component's view will be controlled by @@ -146,7 +148,7 @@ export class UpgradeAdapter { * by way of the `ControlValueAccessor` interface from @angular/forms. Only components that * implement this interface are eligible. * - * ## Supported Features + * ### Supported Features * * - Bindings: * - Attribute: `` @@ -199,13 +201,14 @@ export class UpgradeAdapter { * directive. The adapter will bootstrap AngularJS component from within the Angular * template. * - * ## Mental Model + * @usageNotes + * ### Mental Model * * 1. The component is instantiated by being listed in Angular template. This means that the * host element is controlled by Angular, but the component's view will be controlled by * AngularJS. * - * ## Supported Features + * ### Supported Features * * - Bindings: * - Attribute: `` @@ -283,6 +286,7 @@ export class UpgradeAdapter { * Use this instead of `angular.mock.module()` to load the upgrade module into * the AngularJS testing injector. * + * @usageNotes * ### Example * * ``` @@ -339,6 +343,7 @@ export class UpgradeAdapter { * [`bootstrap`](https://docs.angularjs.org/api/ng/function/angular.bootstrap) method. Unlike * AngularJS, this bootstrap is asynchronous. * + * @usageNotes * ### Example * * ``` @@ -412,7 +417,7 @@ export class UpgradeAdapter { /** * Allows AngularJS service to be accessible from Angular. * - * + * @usageNotes * ### Example * * ``` @@ -452,7 +457,7 @@ export class UpgradeAdapter { /** * Allows Angular service to be accessible from AngularJS. * - * + * @usageNotes * ### Example * * ``` @@ -481,6 +486,7 @@ export class UpgradeAdapter { * @param modules The AngularJS modules that this upgrade module should depend upon. * @returns The AngularJS upgrade module that is declared by this method * + * @usageNotes * ### Example * * ``` diff --git a/packages/upgrade/src/static/upgrade_component.ts b/packages/upgrade/src/static/upgrade_component.ts index 73b7771b37..48da426945 100644 --- a/packages/upgrade/src/static/upgrade_component.ts +++ b/packages/upgrade/src/static/upgrade_component.ts @@ -32,11 +32,12 @@ class Bindings { * A helper class that allows an AngularJS component to be used from Angular. * * *Part of the [upgrade/static](api?query=upgrade%2Fstatic) - * library for hybrid upgrade apps that support AoT compilation* + * library for hybrid upgrade apps that support AoT compilation.* * * This helper class should be used as a base class for creating Angular directives * that wrap AngularJS components that need to be "upgraded". * + * @usageNotes * ### Examples * * Let's assume that you have an AngularJS component called `ng1Hero` that needs diff --git a/packages/upgrade/src/static/upgrade_module.ts b/packages/upgrade/src/static/upgrade_module.ts index bf62d6e49d..001ec7ba83 100644 --- a/packages/upgrade/src/static/upgrade_module.ts +++ b/packages/upgrade/src/static/upgrade_module.ts @@ -90,18 +90,18 @@ import {NgAdapterInjector} from './util'; * This class is an `NgModule`, which you import to provide AngularJS core services, * and has an instance method used to bootstrap the hybrid upgrade application. * - * #### Core AngularJS services - * Importing this `NgModule` will add providers for the core - * [AngularJS services](https://docs.angularjs.org/api/ng/service) to the root injector. + * * Core AngularJS services + * Importing this `NgModule` will add providers for the core + * [AngularJS services](https://docs.angularjs.org/api/ng/service) to the root injector. * - * #### Bootstrap - * The runtime instance of this class contains a {@link UpgradeModule#bootstrap `bootstrap()`} - * method, which you use to bootstrap the top level AngularJS module onto an element in the - * DOM for the hybrid upgrade app. + * * Bootstrap + * The runtime instance of this class contains a {@link UpgradeModule#bootstrap `bootstrap()`} + * method, which you use to bootstrap the top level AngularJS module onto an element in the + * DOM for the hybrid upgrade app. * - * It also contains properties to access the {@link UpgradeModule#injector root injector}, the - * bootstrap `NgZone` and the - * [AngularJS $injector](https://docs.angularjs.org/api/auto/service/$injector). + * It also contains properties to access the {@link UpgradeModule#injector root injector}, the + * bootstrap `NgZone` and the + * [AngularJS $injector](https://docs.angularjs.org/api/auto/service/$injector). * * ### Examples *