0

I have installed Flutter in my mac inside my root folder: /[root]/flutter and I use it on project A.

Now I need to use a different version of Flutter for project B (flutter web), so I cloned Flutter inside project B's root directory. I know that to run it, I have to launch ./flutter/bin/flutter run but how can I setup launch.json for VScode?

Here is my launch.json file:

{
  "version": "0.2.0",
  "configurations": [
    {
      "name": "Web",
      "type": "dart",
      "request": "launch",
      "deviceId": "chrome",
      "args": [
        ??
      ]
    },
  ]
}

I think that if I use it, then it will use the standard Flutter in my mac root and not the Flutter inside the project folder. How can I edit the launch in a way that if I click on the play button in VScode then it will run ./flutter/bin/flutter run?

I'm not interested to use tools like FVM

1 Answer 1

2

Open command palette, enter Preferences: Open User Settings.

Search Flutter Sdk Paths. Add additional flutter sdk from there.

Open flutter project. Do Flutter: Change SDK in the command palette.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.