-
Notifications
You must be signed in to change notification settings - Fork 13.2k
Closed
Labels
QuestionAn issue which isn't directly actionable in codeAn issue which isn't directly actionable in code
Description
TypeScript Version: 2.5.3
Code
// mod.d.ts
declare module 'm' {
export class C {
constructor(s:string,n:number)
test(s: string): void
}
export function func(): void
}
// m.ts
///<reference path='./mod.d.ts'/>
import * as m from 'm'
declare module 'm' {
interface C {
new(d:Date): C
constructor(d:Date): C
(d:Date): C
test2(): void;
test(s:any)
}
}
new m.C( // only (s:string,n:number) , no (d:Date) as expectedExpected behavior:
m.C constructor should display (s:string,n:number) and (d:Date) in intellisense
Actual behavior:
m.C constructor only displays (s:string,n:number)
You learn me how to augment a class from a module, but I'm unable to augment the class constructor.
Thank you in advance for your help.
Metadata
Metadata
Assignees
Labels
QuestionAn issue which isn't directly actionable in codeAn issue which isn't directly actionable in code