chore(TypeScript): fix linting and generate .d.ts

This commit is contained in:
harttle
2019-02-17 18:20:04 +08:00
parent 7ee87008c7
commit fc9ebdb90f
79 changed files with 809 additions and 820 deletions
+4 -3
View File
@@ -3,14 +3,15 @@ import { stringify } from 'src/util/underscore'
import Template from 'src/template/template'
import ITemplate from 'src/template/itemplate'
import Scope from 'src/scope/scope'
import OutputToken from 'src/parser/output-token'
export default class Output extends Template implements ITemplate {
value: Value
constructor(token, strict_filters?) {
constructor (token: OutputToken, strictFilters?: boolean) {
super(token)
this.value = new Value(token.value, strict_filters)
this.value = new Value(token.value, strictFilters)
}
async render(scope: Scope) {
async render (scope: Scope): Promise<string> {
const html = await this.value.value(scope)
return stringify(html)
}