这是indexloc提供的服务,不要输入任何密码
Skip to content
Discussion options

You must be logged in to vote

This is a feature! turbo run dev is meant to run dev in all your workspaces that have that script.

You have some options though:

  1. You can setup your package-one/package.json to have the dev script call the dev:mode1 (and similarly in package-two) like so:

    {
      // ...snipped...
      "scripts": {
        "dev": "npm run dev:mode1"
      }
    }
  2. You can setup your turbo.json with some clever dependsOn:

    {
      "pipeline": {
        "dev": {
          "dependsOn": ["dev:mode1", "dev:modes"]
        }
      }
    }

    If package-one only implements dev:mode1 and package-two only implements dev:mode2 (and neither implement dev), then you should get the behavior you're looking for.

    (Note: I wouldn't really recommend this approach as i…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by mehulkar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants