
committed by
Igor Minar

parent
f48b343af1
commit
0f5c70d563
@ -384,7 +384,7 @@ export class AotCompiler {
|
||||
const summaryJson = new GeneratedFile(srcFileName, summaryFileName(srcFileName), json);
|
||||
if (this.options.enableSummariesForJit) {
|
||||
return [summaryJson, this._codegenSourceModule(srcFileName, forJitOutputCtx)];
|
||||
};
|
||||
}
|
||||
|
||||
return [summaryJson];
|
||||
}
|
||||
|
@ -137,7 +137,7 @@ export class CloneVisitor implements Visitor {
|
||||
|
||||
// Visit all the nodes recursively
|
||||
export class RecurseVisitor implements Visitor {
|
||||
visitText(text: Text, context?: any): any{};
|
||||
visitText(text: Text, context?: any): any {}
|
||||
|
||||
visitContainer(container: Container, context?: any): any {
|
||||
container.children.forEach(child => child.visit(this));
|
||||
@ -151,7 +151,7 @@ export class RecurseVisitor implements Visitor {
|
||||
ph.children.forEach(child => child.visit(this));
|
||||
}
|
||||
|
||||
visitPlaceholder(ph: Placeholder, context?: any): any{};
|
||||
visitPlaceholder(ph: Placeholder, context?: any): any {}
|
||||
|
||||
visitIcuPlaceholder(ph: IcuPlaceholder, context?: any): any{};
|
||||
visitIcuPlaceholder(ph: IcuPlaceholder, context?: any): any {}
|
||||
}
|
||||
|
@ -62,7 +62,7 @@ export class Declaration implements Node {
|
||||
}
|
||||
|
||||
export class Doctype implements Node {
|
||||
constructor(public rootTag: string, public dtd: string){};
|
||||
constructor(public rootTag: string, public dtd: string) {}
|
||||
|
||||
visit(visitor: IVisitor): any { return visitor.visitDoctype(this); }
|
||||
}
|
||||
@ -83,7 +83,7 @@ export class Tag implements Node {
|
||||
|
||||
export class Text implements Node {
|
||||
value: string;
|
||||
constructor(unescapedValue: string) { this.value = _escapeXml(unescapedValue); };
|
||||
constructor(unescapedValue: string) { this.value = _escapeXml(unescapedValue); }
|
||||
|
||||
visit(visitor: IVisitor): any { return visitor.visitText(this); }
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ export class InterpolationConfig {
|
||||
return new InterpolationConfig(markers[0], markers[1]);
|
||||
}
|
||||
|
||||
constructor(public start: string, public end: string){};
|
||||
constructor(public start: string, public end: string) {}
|
||||
}
|
||||
|
||||
export const DEFAULT_INTERPOLATION_CONFIG: InterpolationConfig =
|
||||
|
@ -482,7 +482,7 @@ class SafeSelector {
|
||||
this.index++;
|
||||
return pseudo + replaceBy;
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
restore(content: string): string {
|
||||
return content.replace(/__ph-(\d+)__/g, (ph, index) => this.placeholders[+index]);
|
||||
|
@ -27,13 +27,13 @@ export abstract class SummaryResolver<T> {
|
||||
export class JitSummaryResolver implements SummaryResolver<Type> {
|
||||
private _summaries = new Map<Type, Summary<Type>>();
|
||||
|
||||
isLibraryFile(): boolean { return false; };
|
||||
isLibraryFile(): boolean { return false; }
|
||||
toSummaryFileName(fileName: string): string { return fileName; }
|
||||
fromSummaryFileName(fileName: string): string { return fileName; }
|
||||
resolveSummary(reference: Type): Summary<Type>|null {
|
||||
return this._summaries.get(reference) || null;
|
||||
};
|
||||
}
|
||||
getSymbolsOf(): Type[] { return []; }
|
||||
getImportAs(reference: Type): Type { return reference; }
|
||||
addSummary(summary: Summary<Type>) { this._summaries.set(summary.symbol, summary); };
|
||||
addSummary(summary: Summary<Type>) { this._summaries.set(summary.symbol, summary); }
|
||||
}
|
||||
|
@ -381,10 +381,10 @@ export class MockSummaryResolver implements SummaryResolver<StaticSymbol> {
|
||||
symbol: StaticSymbol,
|
||||
importAs: StaticSymbol
|
||||
}[] = []) {}
|
||||
addSummary(summary: Summary<StaticSymbol>) { this.summaries.push(summary); };
|
||||
addSummary(summary: Summary<StaticSymbol>) { this.summaries.push(summary); }
|
||||
resolveSummary(reference: StaticSymbol): Summary<StaticSymbol> {
|
||||
return this.summaries.find(summary => summary.symbol === reference);
|
||||
};
|
||||
}
|
||||
getSymbolsOf(filePath: string): StaticSymbol[]|null {
|
||||
const symbols = this.summaries.filter(summary => summary.symbol.filePath === filePath)
|
||||
.map(summary => summary.symbol);
|
||||
|
@ -37,7 +37,7 @@ class _Humanizer implements html.Visitor {
|
||||
result: any[] = [];
|
||||
elDepth: number = 0;
|
||||
|
||||
constructor(private includeSourceSpan: boolean){};
|
||||
constructor(private includeSourceSpan: boolean) {}
|
||||
|
||||
visitElement(element: html.Element, context: any): any {
|
||||
const res = this._appendContext(element, [html.Element, element.name, this.elDepth++]);
|
||||
|
@ -2197,7 +2197,7 @@ class TemplateHumanizer implements TemplateAstVisitor {
|
||||
|
||||
constructor(
|
||||
private includeSourceSpan: boolean,
|
||||
private interpolationConfig: InterpolationConfig = DEFAULT_INTERPOLATION_CONFIG){};
|
||||
private interpolationConfig: InterpolationConfig = DEFAULT_INTERPOLATION_CONFIG) {}
|
||||
|
||||
visitNgContent(ast: NgContentAst, context: any): any {
|
||||
const res = [NgContentAst];
|
||||
|
Reference in New Issue
Block a user