After installing angular-seed project, i did the following steps:
Cloned the repository :
git clone https://github.com/angular/angular-seed.git <
If the accepted solution did not work for you. Try the following. This solved the issue in my system.
Make sure the locations of both npm and http-server are added in environment variable 'PATH' (Both user variable and System variable).
If it is not present,
add C:\Users\username\AppData\Roaming\npm
and C:\Users\username\AppData\Roaming\npm\node_modules\http-server
to environment variable 'PATH'
@BenFortune found the answer it was
http-server needs to be installed globally with npm install -g http-server
npm install -g http-server
Use this command to install http-server
module into your project. You can verify this in package.json
For me all that had to be done after the basic install
npm install http-server -g
Is to run as administrator from the project directory this command:
http-server dist/project-name
If you are using Window 10. Then after run
npm install -g http-server
The http-server.cmd
will available in C:\Users\your-user\AppData\Roaming\npm
Environment Variable
Path
(inside admin). You need to run cmd
as Administrator.Path
(inside System variable). You don't need to run cmd
as Administrator.C:\Users\your-user\AppData\Roaming\npm
-> OK
-> OK
-> Re-open the cmd
.http-server
will workYou can fix the issues by doing the following steps,
npm install -g http-server
C:\Users\username\AppData\Roaming\npm