Visual Studio: [Microsoft Visual Studio Community 2019 Version 16.10.2 ]
This extension: [1.3.47]
Description
I was using generator 2 or more years. Probable Today i got new version of extension (it was set to autoupdate)
and i found that i have problem, cause it works different from previous version.
so what i have:
MVC, C# project, apart ".CS" file, PUBLIC class,
TypeScript Settings : "Generate in Global Scope" = flase, "Default Module Name": server
After i change C# class i got generated ".d.ts" file and i found that my project's ".ts" files don't see anymore imterface
from this new-generated .d.ts file. ?! it was working before.
i checked generated file:
-->
export module server {
interface MyClassA { ... }
}
<--
!! before it was little bit different:
-->
declare module server {
interface MyClassA { ... }
}
<--
==> so instead of "declare" now i see "export" => i can not access MyClassA from other .ts file now.
Ofcause i can modify generated .d.ts file by hands and replace export to declare, but ...
!! === > That happens ONLY if C# class is "PUBLIC"!
If class is not PUBLIC i got "declare" and everething works ok.
Steps to recreate
Create some C# class. Set it PUBLIC.
DO "Generate TypeScript Definition"
open any other .ts file and try to use interface from new-generated .d.ts -> it will be "undefined"
Current behavior
=> as i described before Because of "export", module interface can not be accesssed from other .ts files as before
(may be could be used some additional import/include actions, but before it was working well)
Expected behavior
=> Should use "declare" instead of "export" as it was in previous version.
Installed product versions
Description
I was using generator 2 or more years. Probable Today i got new version of extension (it was set to autoupdate) and i found that i have problem, cause it works different from previous version. so what i have: MVC, C# project, apart ".CS" file, PUBLIC class, TypeScript Settings : "Generate in Global Scope" = flase, "Default Module Name": server
After i change C# class i got generated ".d.ts" file and i found that my project's ".ts" files don't see anymore imterface from this new-generated .d.ts file. ?! it was working before. i checked generated file: --> export module server { interface MyClassA { ... } } <-- !! before it was little bit different: --> declare module server { interface MyClassA { ... } } <--
==> so instead of "declare" now i see "export" => i can not access MyClassA from other .ts file now.
Ofcause i can modify generated .d.ts file by hands and replace export to declare, but ...
!! === > That happens ONLY if C# class is "PUBLIC"! If class is not PUBLIC i got "declare" and everething works ok.
Steps to recreate
Current behavior
=> as i described before Because of "export", module interface can not be accesssed from other .ts files as before (may be could be used some additional import/include actions, but before it was working well)
Expected behavior
=> Should use "declare" instead of "export" as it was in previous version.