In ScriptSharp, some JavaScript types might be mapped into classes like arrays for example:
[Imported]
// This is used to map JavaScriptarrays inside C#
public class ArrayList { ... }
When converting, we should detect that ArrayList is to be converted into [] in TypeScript.
Implementation
Implement a separate component responsible for handling the mapping. The component should act at AST Walking level (preferably, in factories) or in Helpers.
Implement type mappings.
Scenario
In ScriptSharp, some JavaScript types might be mapped into classes like arrays for example:
When converting, we should detect that
ArrayList
is to be converted into[]
in TypeScript.Implementation
Implement a separate component responsible for handling the mapping. The component should act at AST Walking level (preferably, in factories) or in Helpers.