Search code examples
npmazure-devopsazure-artifacts

How can I use the npm packages from feed in my VSTS task?


How can I use the npm packages from feed in my VSTS task? As I want to use the cached packages in my build.


Solution

  • If the packages are in your VSTS feed, the simple way is choose corresponding feed in npm task:

    1. Add npm task (Command: install; Working folder with package.json: [package.json folder path])
    2. Choose Registry I select here
    3. Choose your feed

    enter image description here

    Otherwise, just add npm task (Command: install; Working folder with package.json: [package.json folder path]