How can I not generate source map file for production release?


#1

How can I not generate js’s source map file for production release ?
I build with

ionic build android --release

Cordova CLI: 6.3.1
Ionic Framework Version: 2.0.0-rc.0
Ionic CLI Version: 2.1.0
Ionic App Lib Version: 2.1.0-beta.1
OS:
Node Version: v6.5.0

On ionic 2 beta 11 source map file for app.bundle not generated for release.


#2

I tried to add param

rollupConfig.sourceMap = false;

in node_modules@ionic\app-scripts\config\rollup.prod.config.js but uglifyjs create source map again. Then I tried to delete params

inSourceMap: 'main.js.map',
outSourceMap: 'main.js.map',

in node_modules@ionic\app-scripts\config\uglifyjs.config.js, but build uglify not minified js and return error

TypeError: Path must be a string. Received undefined

If I equal this params to empty strings uglifyjs return error:

Error: EISDIR: illegal operation on a directory, open 'c:\apps\myApp\www\build'