A reference to an Angular application running on a page.

For more about Angular applications, see the documentation for bootstrap.

Constructors

ApplicationRef()

Properties

componentFactories → List<ComponentFactory>
Get a list of component factories registered to this application.
read-only
componentTypes → List<Type>
Get a list of component types registered to this application.
read-only
injector Injector
Retrieve the application Injector.
read-only
zone NgZone
Retrieve the application NgZone.
read-only
hashCode → int
The hash code for this object. [...]
read-only, inherited
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited

Methods

bootstrap(ComponentFactory componentFactory) ComponentRef
Bootstrap a new component at the root level of the application. [...]
dispose() → void
Dispose of this application and all of its components.
registerBootstrapListener(void listener(ComponentRef ref)) → void
Register a listener to be called each time bootstrap() is called to bootstrap a new root component.
registerDisposeListener(void dispose()) → void
Register a listener to be called when the application is disposed.
run<R>(dynamic callback()) → dynamic
Runs the given callback in the zone and returns the result of the call. [...]
tick() → void
Invoke this method to explicitly process change detection and its side-effects. [...]
waitForAsyncInitializers() → Future
Returns a promise that resolves when all asynchronous application initializers are done.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() → String
Returns a string representation of this object.
inherited

Operators

operator ==(other) → bool
The equality operator. [...]
inherited