ResponseOptionsArgs

Experimental Type-alias Interface Overview interface ResponseOptionsArgs { } Interface Description Interface for options to construct a Response, based on ResponseInit from the Fetch spec. exported from @angular/http/index, defined in @angular/http/src/interfaces.ts

PlatformRef

Stable Class Class Overview class PlatformRef { bootstrapModuleFactory(moduleFactory: NgModuleFactory<M>) : Promise<NgModuleRef<M>> bootstrapModule(moduleType: Type<M>, compilerOptions?: CompilerOptions|CompilerOptions[]) : Promise<NgModuleRef<M>> onDestroy(callback: () => void) : void injector : Injector destroy() : void destroyed : boolean } Class Description The Angular platform is the entry point for Angular on a web page. Each page ha

NavigationEnd

Stable Class What it does Represents an event triggered when a navigation ends successfully. Class Overview class NavigationEnd { constructor(id: number, url: string, urlAfterRedirects: string) id : number url : string urlAfterRedirects : string toString() : string } Class Description Constructor constructor(id: number, url: string, urlAfterRedirects: string) Class Details id : number url : string urlAfterRedirects : string toString() : string exported from @angular

4. User Input

User input triggers DOM events. We listen to those events with event bindings that funnel updated values back into our components and models. When the user clicks a link, pushes a button, or enters text we want to know about it. These user actions all raise DOM events. In this chapter we learn to bind to those events using the Angular event binding syntax. Run the live example. Binding to user input events We can use Angular event bindings to respond to any DOM event. The syntax is simple. We s

SafeScript

Stable Interface Interface Overview interface SafeScript { } Interface Description Marker interface for a value that's safe to use as JavaScript. exported from @angular/platform-browser/index, defined in @angular/platform-browser/src/security/dom_sanitization_service.ts

wtfStartTimeRange

Experimental Const Variable Export export wtfStartTimeRange Used to mark Async start. Async are similar to scope but they don't have to be strictly nested. The return value is used in the call to [endAsync]. Async ranges only work if WTF has been enabled. someMethod() { var s = wtfStartTimeRange('HTTP:GET', 'some.url'); var future = new Future.delay(5).then((_) { wtfEndTimeRange(s); }); } exported from @angular/core/index defined in @angular/core/src/profile/profile.ts

SelectMultipleControlValueAccessor

Stable Directive Class Overview class SelectMultipleControlValueAccessor { constructor(_renderer: Renderer, _elementRef: ElementRef) value : any onChange : (_: any) => {} onTouched : () => {} writeValue(value: any) : void registerOnChange(fn: (value: any) => any) : void registerOnTouched(fn: () => any) : void setDisabledState(isDisabled: boolean) : void } Selectors select[multiple][formControlName] select[multiple][formControl] select[multiple][ngModel]

ModuleWithComponentFactories

Experimental Class Class Overview class ModuleWithComponentFactories { constructor(ngModuleFactory: NgModuleFactory<T>, componentFactories: ComponentFactory<any>[]) ngModuleFactory : NgModuleFactory<T> componentFactories : ComponentFactory<any>[] } Class Description Combination of NgModuleFactory and ComponentFactorys. Constructor constructor(ngModuleFactory: NgModuleFactory<T>, componentFactories: ComponentFactory<any>[]) Class Details n

BaseResponseOptions

Experimental Class Class Overview class BaseResponseOptions { constructor() } Class Description Subclass of ResponseOptions, with default values. Default values: status: 200 headers: empty Headers object This class could be extended and bound to the ResponseOptions class when configuring an Injector, in order to override the default options used by Http to create Responses. Example (live demo) import {provide} from '@angular/core'; import {bootstrap} from '@angular/platform-browser

1. Introduction

The Tour of Heroes tutorial takes us through the steps of creating an Angular application in TypeScript. Tour of Heroes: the vision Our grand plan is to build an app to help a staffing agency manage its stable of heroes. Even heroes need to find work. Of course we'll only make a little progress in this tutorial. What we do build will have many of the features we expect to find in a full-blown, data-driven application: acquiring and displaying a list of heroes, editing a selected hero's detail,