Overload instead of pointless union

This commit is contained in:
Chris Gedrim
2019-04-08 23:55:25 +01:00
parent 0ad8e6566c
commit 722dcc1a29
+2 -1
View File
@@ -40,7 +40,8 @@ interface Exphbs {
getTemplate(filePath: string, options?: PartialTemplateOptions): Promise<Function>;
getTemplates(dirPath: string, options?: PartialTemplateOptions): Promise<Object>;
render(filePath: string, context: Object, options?: RenderOptions): Promise<string>;
renderView(viewPath: string, optionsOrCallback: ExphbsCallback | any, callback?: ExphbsCallback): void;
renderView(viewPath: string, callback: ExphbsCallback): void;
renderView(viewPath: string, options: any, callback: ExphbsCallback): void;
}
interface ExpressHandlebars {