mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-23 21:00:01 +08:00
Utils is a module, not class
This commit is contained in:
@@ -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>');
|
||||
|
||||
4
handlebars/handlebars.d.ts
vendored
4
handlebars/handlebars.d.ts
vendored
@@ -53,8 +53,8 @@ declare module hbs {
|
||||
static toString(): string;
|
||||
}
|
||||
|
||||
class Utils {
|
||||
static escapeExpression(str: string): string;
|
||||
module Utils {
|
||||
function escapeExpression(str: string): string;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user