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

Commit c143576

Browse files
committed
refactor(shadowDomInjectables): use toClass
1 parent 861b1c1 commit c143576

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/common/shadowDomInjectables.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
11
/// <reference path="../../typings/tsd.d.ts" />
22
/// <reference path="../custom_typings/ng2.d.ts" />
33
import {ShadowDomStrategy, NativeShadowDomStrategy} from 'angular2/core';
4-
import {StyleUrlResolver} from 'angular2/src/render/dom/shadow_dom/style_url_resolver';
54
import {bind} from 'angular2/di';
65
import {document} from 'angular2/src/facade/browser';
76

87
export var hasShadowDom = Boolean(document && document.body && document.body.createShadowRoot);
98

109
export var shadowDomInjectables = (!hasShadowDom) ? [] : [
11-
bind(ShadowDomStrategy).toFactory(
12-
styleUrlResolver => new NativeShadowDomStrategy(styleUrlResolver),
13-
[StyleUrlResolver]
14-
)
10+
bind(ShadowDomStrategy).toClass(NativeShadowDomStrategy)
1511
]

0 commit comments

Comments
 (0)