You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found a strange behaviour when importing a default-exported module from file1 and using it for variable/parameter/return value/whatever... type declarations in file2. Please note that the imported namespace is still visible and works correctly when I use it for variable definitions (e.g. invoking class constructor with new). See the code below:
Instead, for class expression (export default class {... in file1.ts) it works fine, both for type declarations and variable definitions.
The text was updated successfully, but these errors were encountered:
pcan
changed the title
'Cannot find namespace ...' for type declarations using default-exported import
'Cannot find namespace ...' for type declarations using default-exported module import
Aug 21, 2015
I found a strange behaviour when importing a default-exported module from file1 and using it for variable/parameter/return value/whatever... type declarations in file2. Please note that the imported namespace is still visible and works correctly when I use it for variable definitions (e.g. invoking class constructor with new). See the code below:
file1.ts
file2.ts
Instead, for class expression (
export default class {...
in file1.ts) it works fine, both for type declarations and variable definitions.The text was updated successfully, but these errors were encountered: