When I build my angular application with ng build --prod it creates a build for production environment with build optimization, tree-shaking etc.. If I want to make the same kind of build for development environment, what options needs to be passed with ng build command?
Eg.,
ng build --configuration=development --aot --buildOptimizer=true --vendorChunk=false
Basically, what are the cli options one should pass, to make a dev build exactly similar to prod build(except the configuration)?
Other than the option you already used you should add:
--outputHashing= all --sourceMap= false --extractCss=true --namedChunks= false --extractLicenses=true --optimization=trueYou can find here the list of all available options.
If you check your
angular.jsonfile, under:You can read all the used options for a prod build.