I have a file named Server.js
that contains export class Program
and <reference path='mscorlib.ts'/>
. When I build it with
tsc -t ES5 Server.ts --module commonjs --out Server.js
the generated file contains only the compiled source of mscorlib.ts
, but no single sign of Server.ts
. I've expected that there would have been an module.exports = {Program: Program}
directive besides those sources, though. What could be a source of the problem?
The --out
flag only applies to input files that aren't external modules.
See also