【发布时间】:2018-04-25 06:54:15
【问题描述】:
正如标题所说,图像不会显示。这是我在 component.html 中的代码
<div>
<img src="logo.png" alt="...">
</div>
当我查看 chrome 的控制台时,它给了我这个错误
Failed to load resource: the server responded with a status of 404 (Not Found) logo.png
logo.png 文件与 component.html 位于同一文件夹中。 这有什么问题,我该怎么办? 我目前正在使用 Angular CLI:1.7.4;节点:8.11.1;打字稿:2.8.1 希望有人能提供帮助。
【问题讨论】: