From 53d5f365577d8fe14be24248234ed57929de8c9b Mon Sep 17 00:00:00 2001 From: Victor Berchet Date: Mon, 16 Feb 2015 10:21:54 +0100 Subject: [PATCH] feat(application): move classes to the application level injector fixes #649 --- modules/angular2/src/core/application.js | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/modules/angular2/src/core/application.js b/modules/angular2/src/core/application.js index c29108abea..15936ed867 100644 --- a/modules/angular2/src/core/application.js +++ b/modules/angular2/src/core/application.js @@ -24,16 +24,6 @@ var _rootInjector: Injector; // Contains everything that is safe to share between applications. var _rootBindings = [ bind(Reflector).toValue(reflector), - bind(ChangeDetection).toValue(dynamicChangeDetection), - Compiler, - CompilerCache, - TemplateLoader, - TemplateResolver, - DirectiveMetadataReader, - Parser, - Lexer, - bind(ShadowDomStrategy).toValue(new NativeShadowDomStrategy()), - bind(XHR).toValue(new XHRImpl()), ]; export var appViewToken = new OpaqueToken('AppView'); @@ -87,6 +77,16 @@ function _injectorBindings(appComponentType): List { var plugins = [new HammerGesturesPlugin()]; return new EventManager(plugins, zone); }, [VmTurnZone]), + bind(ShadowDomStrategy).toValue(new NativeShadowDomStrategy()), + Compiler, + CompilerCache, + TemplateResolver, + bind(ChangeDetection).toValue(dynamicChangeDetection), + TemplateLoader, + DirectiveMetadataReader, + Parser, + Lexer, + bind(XHR).toValue(new XHRImpl()), ]; }