Mac localhost:8080无法正常工作

时间:2018-03-06 12:58:35

标签: macos google-chrome webpack

我正在使用macOS 10.13.3,当我在默认端口8080上运行我的webpack项目时,我已经使用chrome(任何其他浏览器,firefox或safari也不起作用) :

  

此页面无效

在localhost:8080上,但应用程序在127.0.0.1:8080上运行正常。当我在webpack.config中为任何其他端口(即8081)更改端口时,它在localhost:8081和127.0.0.1:8081上都可以正常工作。

我的/ private / etc / hosts文件:

##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting.  Do not change this entry.
##
127.0.0.1       localhost
255.255.255.255 broadcasthost

::1             localhost

感谢您的帮助。

0 个答案:

没有答案
相关问题