From 1ba83dded25175aa1239dd6ad0d6e0c81a3571ab Mon Sep 17 00:00:00 2001 From: Nickolas Westman Date: Tue, 5 Aug 2014 11:43:05 -0700 Subject: [PATCH] Update underscore.d.ts Template return values not correctly typed - if data is passed it will return a string (no partial templating in underscore) --- underscore/underscore.d.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/underscore/underscore.d.ts b/underscore/underscore.d.ts index 7d9c84f826..9736c28795 100644 --- a/underscore/underscore.d.ts +++ b/underscore/underscore.d.ts @@ -1472,8 +1472,9 @@ interface UnderscoreStatic { * @param settings Settings to use while compiling. * @return Returns the compiled Underscore HTML template. **/ - template(templateString: string, data?: any, settings?: _.TemplateSettings): (...data: any[]) => string; - + template(templateString: string): (...data: any[]) => string; + template(templateString: string, data: any, settings?: _.TemplateSettings): string; + /** * By default, Underscore uses ERB-style template delimiters, change the * following template settings to use alternative delimiters.