2016-06-23 12:47:54 -04:00
|
|
|
/**
|
|
|
|
* @license
|
2020-05-19 15:08:49 -04:00
|
|
|
* Copyright Google LLC All Rights Reserved.
|
2016-06-23 12:47:54 -04:00
|
|
|
*
|
|
|
|
* Use of this source code is governed by an MIT-style license that can be
|
|
|
|
* found in the LICENSE file at https://angular.io/license
|
|
|
|
*/
|
|
|
|
|
2016-04-28 20:50:03 -04:00
|
|
|
import {DebugElement} from '@angular/core';
|
2016-06-08 19:38:52 -04:00
|
|
|
import {By} from '@angular/platform-browser';
|
2015-12-03 18:49:09 -05:00
|
|
|
|
2020-04-13 19:40:21 -04:00
|
|
|
let debugElement: DebugElement = undefined!;
|
2015-12-03 18:49:09 -05:00
|
|
|
class MyDirective {}
|
|
|
|
|
|
|
|
// #docregion by_all
|
2016-01-14 00:35:21 -05:00
|
|
|
debugElement.query(By.all());
|
2015-12-03 18:49:09 -05:00
|
|
|
// #enddocregion
|
|
|
|
|
|
|
|
// #docregion by_css
|
2016-01-14 00:35:21 -05:00
|
|
|
debugElement.query(By.css('[attribute]'));
|
2015-12-03 18:49:09 -05:00
|
|
|
// #enddocregion
|
|
|
|
|
|
|
|
// #docregion by_directive
|
2016-01-14 00:35:21 -05:00
|
|
|
debugElement.query(By.directive(MyDirective));
|
2015-12-03 18:49:09 -05:00
|
|
|
// #enddocregion
|