Help Angular by taking a 1 minute survey!Go to surveyHome

DebugElement

      
      
  1. interface DebugElement extends DebugNode {
  2. name: string
  3. properties: {...}
  4. attributes: {...}
  5. classes: {...}
  6. styles: {...}
  7. childNodes: DebugNode[]
  8. nativeElement: any
  9. children: DebugElement[]
  10. query(predicate: Predicate<DebugElement>): DebugElement
  11. queryAll(predicate: Predicate<DebugElement>): DebugElement[]
  12. queryAllNodes(predicate: Predicate<DebugNode>): DebugNode[]
  13. triggerEventHandler(eventName: string, eventObj: any): void
  14.  
  15. // inherited from core/DebugNode
  16. listeners: EventListener[]
  17. parent: DebugElement | null
  18. nativeNode: any
  19. injector: Injector
  20. componentInstance: any
  21. context: any
  22. references: {...}
  23. providerTokens: any[]
  24. }

Properties

Property Description
name: string Read-only.
properties: { [key: string]: any; } Read-only.
attributes: { [key: string]: string | null; } Read-only.
classes: { [key: string]: boolean; } Read-only.
styles: { [key: string]: string | null; } Read-only.
childNodes: DebugNode[] Read-only.
nativeElement: any Read-only.
children: DebugElement[] Read-only.

Methods

      
      query(predicate: Predicate<DebugElement>): DebugElement
    
Parameters
predicate Predicate
Returns

DebugElement

queryAll(predicate: Predicate<DebugElement>): DebugElement[]
      
      queryAll(predicate: Predicate<DebugElement>): DebugElement[]
    
Parameters
predicate Predicate
Returns

DebugElement[]

queryAllNodes(predicate: Predicate<DebugNode>): DebugNode[]
      
      queryAllNodes(predicate: Predicate<DebugNode>): DebugNode[]
    
Parameters
predicate Predicate
Returns

DebugNode[]

triggerEventHandler(eventName: string, eventObj: any): void
      
      triggerEventHandler(eventName: string, eventObj: any): void
    
Parameters
eventName string
eventObj any
Returns

void