/// <amd-module />
By default AMD modules are generated anonymous. This can lead to problems when other tools are used to process the resulting modules, such as bundlers (e.g. r.js
).
The amd-module
directive allows passing an optional module name to the compiler:
amdModule.ts
///<amd-module name="NamedModule"/> export class C { }
Will result in assigning the name NamedModule
to the module as part of calling the AMD define
:
amdModule.js
define("NamedModule", ["require", "exports"], function (require, exports) { var C = (function () { function C() { } return C; })(); exports.C = C; });
Please login to continue.