Closed
Description
Hello!
I'm trying to build a module that the user (developer) will consume by either using:
- Pure javascript: He'll have my
class
loaded in the global scope, for example. - Commonjs: He'll be able to call it using
require
- and maybe with SystemJS. - AMD: He'll be able to use it with RequireJS and maybe with SystemJS.
- ES6: He'll be able to use it with the ES6 syntax.
So, right now I'm using gulp-typescript
to transpile my code to the dist
folder. I transpile once for commonjs
, once for amd
, once for es6
.. but it seems that there's no way to transpile to pure Javascript (other than using the module syntax inside my .ts
file).
Is there any way to accomplish this?
Thanks in advance!