Fixing the build delayed until bower/npm packages finish restoring.
Angular Logo

Fixing the build delayed until bower/npm packages finish restoring.

Deciding that it's time that I got familiar with Angular, I thought I'd create a Visual Studio Project and have a poke around. I duly created the project and began the build just to see what it looks like. It was then that I received the 'Fixing the build delayed until bower/npm packages finish restoring.' message and duly waited... and waited... and waited...

It would appear that the message, nice and informative as it is, appears to be missing a little bit of information. Turns out it would have been a bit more useful if the message had said 'Fixing the build delayed until bower/npm packages have been installed by you!!!'

With that in mind, and to save my sanity the next time that I do this, I've decided to document completely, how to do this. I say completely as I've lost count of the number of tutorials and help sites that say 'Do x... then do y...' completely missing out the fact that you should have done 'ABC' first assuming that you knew that already, so here goes...

First off you'll need npm which is: (yes I'm going to be that pedantic) The default Package manager for the JavaScript runtime environment Node.js. You can find all you need about npm at https://docs.npmjs.com/. To install (on Windows, I'm not an Apple user) go to https://nodejs.org/en/ and download the MSI. Once you've got that installed you can then either open up a command prompt, PowerShell or Node.js command prompt window and 'CD' (I'm really really being that pedantic) to the Project folder. Note. That is the Project folder, not the Solution folder, see below.

Incorrect:

CD C:\VS\For Testing\AngularTest\






Correct:

CD C:\VS\For Testing\AngularTest\AngularTest










Note: The folder node_modules above won't exist until after you've done the next step.

Once you've CD'd (is that a word?... Well it is now.) You then type

npm install

Wait for it to do its magic and you should be set. If you've done all of this with your project open, you will have to shut down your project and re-open in before it will build, otherwise just open the project and it should now build.




要查看或添加评论,请登录

Paul Whiting的更多文章

社区洞察

其他会员也浏览了