1. Install Homebrew

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Copy the code

If an error curl: (7) Failed to connect to port 443 raw.githubusercontent.com: Connection refused, terminal need to hang the VPN

2. View the native Ruby version

View installed Ruby

rvm list 
Copy the code

If the local version is less than 2.6, run the RVM list known command and select >= 2.6

RVM install 2.6Copy the code

The local Ruby environment must >= 2.6 or an error will be reported

Updating Homebrew...
/usr/local/Homebrew/Library/Homebrew/brew.rb:10:in `<main>': Homebrew must be run under Ruby 2.6! You'Re running 2.3.7. (RuntimeError)Copy the code

3. Use Homebrew to install dart

Brew install dart (stable version, updated every 6 weeks) brew install dart -- --devel (latest development version, updated every week)Copy the code

Brew install dart. If Xcode alone is not sufficient on Mojave, run xcode-select –install. After installation, proceed to brew Install Dart

4. Check the installed environment

brew info dart
Copy the code

5. Download and install the IDE

Choose the edition, click Download to Download www.jetbrains.com/idea/downlo…

After the installation is complete, select 30 days, enter your email address and click Trial

6. Install the Dart plug-in in the IDE

Open the IDE and select the Plugins option

Search for the Dart plug-in and click Install

When the installation is complete, click Restart IDE, click Restart

Start your Dart journey now

7, other

The Dart’s official website

Introduction and use of Homebrew