116 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
		
		
			
		
	
	
			116 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
|  | 
 | ||
|  | p.location-badge. | ||
|  |   exported from <a href='../router'>angular2/router</a> | ||
|  |   defined in <a href="https://github.com/angular/angular/tree/2.0.0-alpha.32/modules/angular2/src/router/router_outlet.ts#L12-L143">angular2/src/router/router_outlet.ts (line 12)</a> | ||
|  | 
 | ||
|  | :markdown | ||
|  |   A router outlet is a placeholder that Angular dynamically fills based on the application's route. | ||
|  |    | ||
|  |   ## Use | ||
|  |    | ||
|  |   ``` | ||
|  |   <router-outlet></router-outlet> | ||
|  |   ``` | ||
|  |    | ||
|  |    | ||
|  | .l-main-section | ||
|  |   h2 Members | ||
|  |   .l-sub-section | ||
|  |     h3 constructor | ||
|  | 
 | ||
|  |      | ||
|  |     pre.prettyprint | ||
|  |       code. | ||
|  |         constructor(_elementRef: ElementRef, _loader: DynamicComponentLoader, _parentRouter:Router, nameAttr: string) | ||
|  |      | ||
|  |     :markdown | ||
|  |        | ||
|  |        | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  |   .l-sub-section | ||
|  |     h3 childRouter | ||
|  | 
 | ||
|  |      | ||
|  |     :markdown | ||
|  | 
 | ||
|  |        | ||
|  |        | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  |   .l-sub-section | ||
|  |     h3 commit | ||
|  | 
 | ||
|  |      | ||
|  |     pre.prettyprint | ||
|  |       code. | ||
|  |         commit(instruction: Instruction) | ||
|  |      | ||
|  |     :markdown | ||
|  | 
 | ||
|  |       Given an instruction, update the contents of this outlet. | ||
|  |        | ||
|  |        | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  |   .l-sub-section | ||
|  |     h3 canDeactivate | ||
|  | 
 | ||
|  |      | ||
|  |     pre.prettyprint | ||
|  |       code. | ||
|  |         canDeactivate(nextInstruction: Instruction) | ||
|  |      | ||
|  |     :markdown | ||
|  | 
 | ||
|  |       Called by Router during recognition phase | ||
|  |        | ||
|  |        | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  |   .l-sub-section | ||
|  |     h3 canReuse | ||
|  | 
 | ||
|  |      | ||
|  |     pre.prettyprint | ||
|  |       code. | ||
|  |         canReuse(nextInstruction: Instruction) | ||
|  |      | ||
|  |     :markdown | ||
|  | 
 | ||
|  |       Called by Router during recognition phase | ||
|  |        | ||
|  |        | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  |   .l-sub-section | ||
|  |     h3 deactivate | ||
|  | 
 | ||
|  |      | ||
|  |     pre.prettyprint | ||
|  |       code. | ||
|  |         deactivate(nextInstruction: Instruction) | ||
|  |      | ||
|  |     :markdown | ||
|  | 
 | ||
|  |        | ||
|  |        | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 | ||
|  | 
 |