1 Downloadnode.js
Official website address: https://nodejs.org
after the download is complete at the command line command $ node -v
and $ npm -v
check the version, make sure the installation was successful.
2 Download live-server
Enter in a terminal:$ npm install live-server -g
3 Turn on the live-server service
Terminal enters the destination folder, then enter the terminal:
$ live-server
此时文件代码有变化立刻反应到浏览器中
4 Close the live-server service
Ankuaichajian CTRL-C
prompted to close the final batch operations
1 Downloadnode.js
Official website address: https://nodejs.org
after the download is complete at the command line command $ node -v
and $ npm -v
check the version, make sure the installation was successful.
2 Download live-server
Enter in a terminal:$ npm install live-server -g
3 Turn on the live-server service
Terminal enters the destination folder, then enter the terminal:
$ live-server
此时文件代码有变化立刻反应到浏览器中
4 Close the live-server service
Ankuaichajian CTRL-C
prompted to close the final batch operations