-
Install NVM:
- Open Command Prompt.
- Download and run the NVM installation script for Windows from GitHub:
nvm-setup.zip
- Follow the installation instructions provided.
-
Install Node.js using NVM:
- Continue in Command Prompt.
- Install the latest version of Node.js:
nvm install latest
- Use the installed version:
nvm use latest
-
Verify Installation:
- Ensure
nvm
,node
, andnpm
are installed correctly:nvm version node -v npm -v
- Ensure
-
Install Homebrew (if not already installed):
- Open Terminal.
- Run the following command to install Homebrew:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
-
Install NVM:
- Continue in Terminal.
- Install NVM using Homebrew:
brew install nvm
- Create NVM directory:
mkdir ~/.nvm
- Add the following lines to your
~/.zshrc
or~/.bash_profile
file:export NVM_DIR="$HOME/.nvm" [ -s "/usr/local/opt/nvm/nvm.sh" ] && . "/usr/local/opt/nvm/nvm.sh" [ -s "/usr/local/opt/nvm/etc/bash_completion.d/nvm" ] && . "/usr/local/opt/nvm/etc/bash_completion.d/nvm"
- Source your profile script:
source ~/.zshrc # or source ~/.bash_profile
-
Check Default Directory:
- Open Terminal.
- Ensure you are in the default directory where NVM will install Node.js. You can check this by running:
cd ~
-
Install Node.js using NVM:
- Install the latest version of Node.js:
nvm install node
- Use the installed version:
nvm use node
- Install the latest version of Node.js:
-
Verify Installation:
- Ensure
nvm
,node
, andnpm
are installed correctly:nvm --version node -v npm -v
- Ensure
- Install Project Dependencies:
- Navigate to the project directory and install dependencies:
cd path/to/project npm ci
- Navigate to the project directory and install dependencies:
- Run
npm start