ViswaKanth Tangudu
ViswaKanth Tangudu

Reputation: 11

live-server : The term 'live-server' is not recognized as the name of a cmdlet, function, script file, or operable program

live-server : The term 'live-server' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:1

Already installed node js

PS C:\Javascript\complete-javascript-course-master\13-Advanced-DOM-Bankist\starter> node -v v16.1.0

Upvotes: 1

Views: 4021

Answers (3)

Omid Ostovari
Omid Ostovari

Reputation: 372

Step 1: go to project directory. cd PROJECT-PATH

Step 2: Run this command npm install live-server --save-dev

Step 3: After Created node_modules directory (now live-server file is exist in node_modules/bin directory.) you must run ./node_modules/.bin/live-server

Upvotes: 0

nazanin azar
nazanin azar

Reputation: 1

You should install the package globally in the terminal like this: npm i -g live-server and then run your live server in terminal: live-server (name of your folder)

Upvotes: 0

aaron
aaron

Reputation: 366

Most likely if you had just installed it, it won't be in your PATH yet. You would need to restart your terminal for your PATH variable to update.

Upvotes: 1

Related Questions