Skip to content
This repository was archived by the owner on Feb 22, 2018. It is now read-only.

Commit 3ec5d75

Browse files
committed
feat(probe): add directive getter and export ElementProbe type.
This brings feature parity to ElementProbe with the deprecated Probe directive.
1 parent 3b7b0d6 commit 3ec5d75

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

lib/core_dom/view_factory.dart

+2
Original file line numberDiff line numberDiff line change
@@ -207,4 +207,6 @@ class ElementProbe {
207207
final modelExpressions = <String>[];
208208

209209
ElementProbe(this.parent, this.element, this.injector, this.scope);
210+
211+
dynamic directive(Type type) => injector.get(type);
210212
}

lib/introspection.dart

+2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ import 'package:angular/core_dom/module_internal.dart';
1313
import 'package:angular/core_dom/directive_injector.dart' show DirectiveInjector;
1414
import 'package:angular/core/static_keys.dart';
1515

16+
export 'package:angular/core_dom/module_internal.dart' show ElementProbe;
17+
1618

1719
/**
1820
* A global write only variable which keeps track of objects attached to the

0 commit comments

Comments
 (0)