npm script command to run a script command from another package.json

后端 未结 3 1060
情书的邮戳
情书的邮戳 2021-02-02 07:20

I have two separate projects that use npm - so I have both :
some_base_folder/projectA/package.json and some_base_folder/projectB/package.json

3条回答
  •  梦谈多话
    2021-02-02 08:02

    well it turns out to be quite simple:

    "scripts": {
      test_projectA:"cd ../projectA && npm run-script test"
    }
    

提交回复
热议问题