本文介绍了如何从3000更改服务器端口?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我刚刚结束了Angular 2的教程,我找不到将localhost端口从3000更改为8000的方法.在我的package.json文件中,有一行"start": "concurrent \"npm run tsc:w\" \"npm run lite\" "相信是相关的,但我不确定.
I just ended the tutorial of Angular 2 and I can't find a way to change the localhost port from 3000 to 8000. In my package.json file there's the line "start": "concurrent \"npm run tsc:w\" \"npm run lite\" " that I believe is related but I'm not sure.
推荐答案您可以按照文档 github/johnpapa/lite-server#custom-configuration
例如
{ "port": 8000, "files": ["./src/**/*.{html,htm,css,js}"], "server": { "baseDir": "./src" } }更多推荐
如何从3000更改服务器端口?
发布评论