diff --git a/src/interfaces.ts b/src/interfaces.ts index 9773d330d3..657ebea7e1 100644 --- a/src/interfaces.ts +++ b/src/interfaces.ts @@ -47,6 +47,7 @@ export interface CompileOptions { amd?: { id?: string; }; + bind?: boolean; outputFilename?: string; cssOutputFilename?: string; diff --git a/src/parse/index.ts b/src/parse/index.ts index 995a38f675..2f67086370 100644 --- a/src/parse/index.ts +++ b/src/parse/index.ts @@ -22,6 +22,7 @@ class ParseError extends CompileError { interface ParserOptions { filename?: string; + bind?: boolean; } type ParserState = (parser: Parser) => (ParserState | void); @@ -29,6 +30,7 @@ type ParserState = (parser: Parser) => (ParserState | void); export class Parser { readonly template: string; readonly filename?: string; + readonly bind: boolean; index: number; stack: Array; @@ -45,6 +47,7 @@ export class Parser { this.template = template.replace(/\s+$/, ''); this.filename = options.filename; + this.bind = options.bind !== false; this.index = 0; this.stack = [];