2016-04-12 12:40:37 -04:00
|
|
|
import {RuntimeCompiler_} from "./runtime_compiler";
|
2015-09-14 18:59:09 -04:00
|
|
|
export {TemplateCompiler} from './template_compiler';
|
2016-04-12 12:40:37 -04:00
|
|
|
export {
|
|
|
|
CompileDirectiveMetadata,
|
|
|
|
CompileTypeMetadata,
|
|
|
|
CompileTemplateMetadata
|
|
|
|
} from './directive_metadata';
|
2015-09-14 18:59:09 -04:00
|
|
|
export {SourceModule, SourceWithImports} from './source_module';
|
2015-11-09 17:33:22 -05:00
|
|
|
export {PLATFORM_DIRECTIVES, PLATFORM_PIPES} from 'angular2/src/core/platform_directives_and_pipes';
|
2015-12-03 19:14:34 -05:00
|
|
|
export * from 'angular2/src/compiler/template_ast';
|
|
|
|
export {TEMPLATE_TRANSFORMS} from 'angular2/src/compiler/template_parser';
|
2015-11-13 14:21:16 -05:00
|
|
|
import {assertionsEnabled, Type, CONST_EXPR} from 'angular2/src/facade/lang';
|
2015-10-11 01:11:13 -04:00
|
|
|
import {provide, Provider} from 'angular2/src/core/di';
|
2015-11-05 17:07:57 -05:00
|
|
|
import {TemplateParser} from 'angular2/src/compiler/template_parser';
|
|
|
|
import {HtmlParser} from 'angular2/src/compiler/html_parser';
|
|
|
|
import {TemplateNormalizer} from 'angular2/src/compiler/template_normalizer';
|
|
|
|
import {RuntimeMetadataResolver} from 'angular2/src/compiler/runtime_metadata';
|
|
|
|
import {ChangeDetectionCompiler} from 'angular2/src/compiler/change_detector_compiler';
|
|
|
|
import {StyleCompiler} from 'angular2/src/compiler/style_compiler';
|
2015-12-02 13:35:51 -05:00
|
|
|
import {ViewCompiler} from 'angular2/src/compiler/view_compiler';
|
|
|
|
import {ProtoViewCompiler} from 'angular2/src/compiler/proto_view_compiler';
|
2015-11-05 17:07:57 -05:00
|
|
|
import {TemplateCompiler} from 'angular2/src/compiler/template_compiler';
|
2015-09-18 13:33:23 -04:00
|
|
|
import {ChangeDetectorGenConfig} from 'angular2/src/core/change_detection/change_detection';
|
2015-10-02 10:37:23 -04:00
|
|
|
import {Compiler} from 'angular2/src/core/linker/compiler';
|
2015-11-05 17:07:57 -05:00
|
|
|
import {RuntimeCompiler} from 'angular2/src/compiler/runtime_compiler';
|
|
|
|
import {ElementSchemaRegistry} from 'angular2/src/compiler/schema/element_schema_registry';
|
|
|
|
import {DomElementSchemaRegistry} from 'angular2/src/compiler/schema/dom_element_schema_registry';
|
2015-12-05 05:21:38 -05:00
|
|
|
import {UrlResolver, DEFAULT_PACKAGE_URL_PROVIDER} from 'angular2/src/compiler/url_resolver';
|
2015-10-02 14:10:08 -04:00
|
|
|
import {Parser, Lexer} from 'angular2/src/core/change_detection/change_detection';
|
2015-09-18 13:33:23 -04:00
|
|
|
|
2015-11-13 14:21:16 -05:00
|
|
|
function _createChangeDetectorGenConfig() {
|
|
|
|
return new ChangeDetectorGenConfig(assertionsEnabled(), false, true);
|
2015-09-18 13:33:23 -04:00
|
|
|
}
|
2015-11-13 14:21:16 -05:00
|
|
|
|
2015-12-03 18:49:09 -05:00
|
|
|
/**
|
|
|
|
* A set of providers that provide `RuntimeCompiler` and its dependencies to use for
|
|
|
|
* template compilation.
|
|
|
|
*/
|
2016-04-12 12:40:37 -04:00
|
|
|
export const COMPILER_PROVIDERS: Array<Type | Provider | any[]> = CONST_EXPR([
|
|
|
|
Lexer,
|
|
|
|
Parser,
|
|
|
|
HtmlParser,
|
|
|
|
TemplateParser,
|
|
|
|
TemplateNormalizer,
|
|
|
|
RuntimeMetadataResolver,
|
|
|
|
DEFAULT_PACKAGE_URL_PROVIDER,
|
|
|
|
StyleCompiler,
|
|
|
|
ProtoViewCompiler,
|
|
|
|
ViewCompiler,
|
2015-11-13 14:21:16 -05:00
|
|
|
ChangeDetectionCompiler,
|
|
|
|
new Provider(ChangeDetectorGenConfig, {useFactory: _createChangeDetectorGenConfig, deps: []}),
|
2016-04-12 12:40:37 -04:00
|
|
|
TemplateCompiler,
|
|
|
|
new Provider(RuntimeCompiler, {useClass: RuntimeCompiler_}),
|
|
|
|
new Provider(Compiler, {useExisting: RuntimeCompiler}),
|
|
|
|
DomElementSchemaRegistry,
|
|
|
|
new Provider(ElementSchemaRegistry, {useExisting: DomElementSchemaRegistry}),
|
|
|
|
UrlResolver
|
2015-11-13 14:21:16 -05:00
|
|
|
]);
|