Find by Category

Setting up Bash WSL on Windows 10 (npm, nodejs)


Just run these commands from bash ..

This will install nodejs 14, if you want to install latest or older version of nodejs.. you should change /setup_14.x like /setup_12.x

Install NodeJS on Ubuntu

curl -sL | sudo -E bash -
sudo apt-get install -y nodejs
sudo apt install npm

Run the following commands if you are using WSL on Windows 10 and npm and node do not run and returns error.

source ~/.profile

Setting up Bash as default on vs code

Go to setting and click the page icon on the right top..

Paste the following code in #settings.json to set bash/wsl as default terminal in vs code.

"": "C:\\Windows\\System32\\bash.exe",

Now you should see bash as default whenever you launch terminal