gulp-typescript-helper
Provides a single simplified means for building TypeScript with:
- Source Maps
- Declaration Files
- Minification
Other features:
- Resolves using promises instead of streams for more easy of use and flexibility.
- Use whatever Promise library you want.
Usage:
Write your tasks like this:
import {Target, Module, CoreTypeScriptOptions, BuildHelper} from "gulp-typescript-helper";
const DEFAULTS:CoreTypeScriptOptions = {
noImplicitAny: true,
removeComments: true,
noEmitHelpers: true,
sourceMap: true,
declaration: true
});
const builder = BuildHelper
.inject(PromiseFactory)
.fromTo(PATH.SOURCE, "./dist" , DEFAULTS);
gulp.task(
TASK.DIST_UMD,
()=> builder
.init(
MODULE.UMD + '.min',
TARGET.ES5,
MODULE.UMD)
.clear()
.minify()
.execute()
.then(()=>
)
);
See more real use cases and examples here:
https://github.com/electricessence/TypeScript.NET/blob/master/_gulp/dist.ts