You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
angular-cli: 1.0.0-beta.16
node: 6.7.0 (I also tried it on 5.12.0 and 4.6.0)
os: darwin x64
Repro steps.
npm install -g angular-cli@latest
ng new build-watch
cd build-watch
ng build -w
The log given by the failure.
Path must be a string. Received null
TypeError: Path must be a string. Received null
at assertPath (path.js:7:11)
at Object.resolve (path.js:1148:7)
at Class.run (/Users/jonathansamples/projects/build-watch/node_modules/angular-cli/tasks/build-webpack-watch.js:14:26)
at Class.run (/Users/jonathansamples/projects/build-watch/node_modules/angular-cli/commands/build.js:50:26)
at Class.<anonymous> (/Users/jonathansamples/projects/build-watch/node_modules/angular-cli/lib/models/command.js:152:17)
at tryCatch (/Users/jonathansamples/projects/build-watch/node_modules/rsvp/dist/lib/rsvp/-internal.js:215:12)
at invokeCallback (/Users/jonathansamples/projects/build-watch/node_modules/rsvp/dist/lib/rsvp/-internal.js:230:13)
at publish (/Users/jonathansamples/projects/build-watch/node_modules/rsvp/dist/lib/rsvp/-internal.js:198:7)
at flush (/Users/jonathansamples/projects/build-watch/node_modules/rsvp/dist/lib/rsvp/asap.js:85:5)
at _combinedTickCallback (internal/process/next_tick.js:67:7)
at process._tickCallback (internal/process/next_tick.js:98:9)
same happens on Windows. There is one main reason why we would use ng build -watch over ng serve.. we need the generated map files on the disk instead of in-memory on the webpack dev server so we will be able to debug from webstorm..
@denkomanceski@jonnysamps to get around this run the following: ng build --watch -o dist/ Adding the out param seems to fix it. We use it as well because we proxy the site and need physical files on disk.
Reacted by Christina Huege, Dan Cavanagh, cedvdb, Sebastian Clausen, witt, Rolands Strods, abdallahbedir, Demis Bellot and Gerald H.
Reacted by Dan Cavanagh, stangrin3, witt and Pankaj Parkar
I have a directory called test. Inside this directory are two other directories. One for my electron program and the other an angular app built using ng new.
Now I've set my angular-cli.json to output to "outDir": "../electron/src/gui"
When I do a normal ng build, it creates the files as it should. However if I use ng build --watch with that directory and change anything, it does not update anything.
Activity
denkomanceski commentedon Oct 4, 2016
same happens on Windows. There is one main reason why we would use ng build -watch over ng serve.. we need the generated map files on the disk instead of in-memory on the webpack dev server so we will be able to debug from webstorm..
coryrylan commentedon Oct 5, 2016
@denkomanceski @jonnysamps to get around this run the following:
ng build --watch -o dist/Adding the out param seems to fix it. We use it as well because we proxy the site and need physical files on disk.jonnysamps commentedon Oct 5, 2016
Good tip @splintercode. Works like a charm.
AnthoniG commentedon Oct 5, 2016
Unfortunately it does not seem to work for me.
I have a directory called test. Inside this directory are two other directories. One for my electron program and the other an angular app built using ng new.
Now I've set my angular-cli.json to output to
"outDir": "../electron/src/gui"When I do a normal ng build, it creates the files as it should. However if I use ng build --watch with that directory and change anything, it does not update anything.
Btw: I am using windows7 64bit
fix(build): use outputPath from config
fix(build): use outputPath from config
fix(build): use outputPath from config
fix(build): use outputPath from config
fix(build): use outputPath from config
angular-automatic-lock-bot commentedon Sep 7, 2019
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.
fix(build): use outputPath from config