I\'d like to to know if it is possible to hook into angular-cli\'s build/watch command:
ng build /w
which generates files and dr
You should create your own node build script which calls the ng build
command and after that copies the files to a directory:
let thread = exec('ng build -e=prod --prod', { maxBuffer: 1024 * 5000});
thread.on('close', (data) => {
//do your moving stuff here
});
There is no way to hook into the cli
(yet), and I don't think they will allow it. As far as I remember, they like to keep things closed there, because this way they are able to change/tune/update the build process a lot, without older builds going haywire