javascript - Disabling AngularJS debug data in a gulp / typescript production build -


what best way disable debug data gulp production build? documented way disable debug data is:

myapp.config(['$compileprovider', function ($compileprovider) {   $compileprovider.debuginfoenabled(false); }]); 

i'm using gulp-typescript build app. since typescript has no conditional compilation, have no idea how set parameter true false in gulp production build without changing code.

the solution can think of conditionally add debug.ts or release.ts gulp.src gulp-typescript. know better solution?

you can use gulp-ng-constant application configuration. here is practical example. thing constants available during config phase, suits case.

but adding config files conditionally appropriate way.


Comments

Popular posts from this blog

javascript - Karma not able to start PhantomJS on Windows - Error: spawn UNKNOWN -

Nuget pack csproj using nuspec -

c# - Display ASPX Popup control in RowDeleteing Event (ASPX Gridview) -