Utils is a module, not class

This commit is contained in:
Igor Rogatty
2015-01-23 15:27:16 +01:00
parent 890265f436
commit 7159e9a3dd
2 changed files with 4 additions and 2 deletions

View File

@@ -78,3 +78,5 @@ Handlebars.registerHelper('list', (items: any, fn: (item: any) => string) => {
Handlebars.registerHelper('fullName', (person: typeof context.author) => {
return person.firstName + ' ' + person.lastName;
});
var escapedExpression = Handlebars.Utils.escapeExpression('<script>alert(\'xss\');</script>');

View File

@@ -53,8 +53,8 @@ declare module hbs {
static toString(): string;
}
class Utils {
static escapeExpression(str: string): string;
module Utils {
function escapeExpression(str: string): string;
}
}