【发布时间】:2019-12-16 08:11:19
【问题描述】:
我正在尝试遵循本指南https://angular.io/guide/setup-local。我安装了 node.js 和 angular cli 并构建了默认应用程序:
ng new my-app
现在我想启动应用程序:
cd my-app
ng serve --open
一切正常:
** Angular Live Development Server is listening on localhost:4200, open your browser on https://localhost:4200/ **
i 「wdm」: Compiled successfully.
但是当我在 Chrome 中打开页面时,它是 privacy error
当我尝试在 Firefox 中打开它时,一切都很好。 我尝试使用下一个命令启动应用程序:
ng serve --open --ssl true
还是同样的错误。 有什么帮助吗?此时我不需要 https,我只想能够在 Chrome 中打开我的应用程序。
+
我发布了错误的错误代码。我明白了:ERR_SSL_PROTOCOL_ERROR
【问题讨论】:
-
您似乎正在尝试使用 SSL 协议打开您的网站(通过使用
https://或端口:443。您能否提供您用于访问您的应用程序的 URL?跨度> -
为什么要尝试使用 --ssl 选项?有什么需要吗?跳过它。对于本地开发,通常只需 http 就足够了
标签: angular google-chrome ssl https localhost