What is the TypeScript way of loading modules dynamically (path to the module is known at runtime)? I tried this one:
var x = "someplace"
import a = module(x)
$ tsc test.ts
/tmp/test.ts(2,19): error TS1003: Identifier expected.
/tmp/test.ts(2,20): error TS1005: ';' expected.
You need to specify a hard coded string. Variables will not work because that would mean code would have to exist outside the
However you could do it yourself if you do not use typescript AMD feature and just use requirejs.d.ts