TypeScript Version: 2.0.3
Code
Foo.ts:
export default function Foo(): any {}
Bar.ts:
import Foo from './path/to/my/fn/Foo'
export default class Bar {
constructor(
private Foo: Foo, // Second Foo is underlined. Error: 'Cannot find name Foo.'
) {}
}
When using Foo as a type definition, it throws an error. Is this a intended behavior? Can you please refer me to the specification where is this discussed or help me with this? Thank you!