0

I started developing a web application using Angularjs. I tried to add an image to the page. The image is not displayed on the page.

img src="src/assets/img/f1.png" alt="icon"

I used above mentioned tag and path inside <>. Can anyone give step by step instructions to add an image using Angularjs?

Thank you!

bob
  • 2,674
  • 1
  • 29
  • 46
  • `icon` - check your image path (right click "open-with"). In general your Q is too general - please read this article: https://stackoverflow.com/help/how-to-ask. Related Q: https://stackoverflow.com/questions/42793292/how-to-load-image-and-other-assets-in-angular-an-project. General broken image: https://blog.teamtreehouse.com/how-to-fix-a-broken-image – Ezra Siton Sep 02 '20 at 21:42
  • could you give your project tree to see the folders and files, tell which file has the `` and were is the `f1.png` – sgClaudia98 Sep 02 '20 at 22:09

1 Answers1

0

Try relative path from place you are. ./ means current directory ../ means higher directory try src="../assets/f1.png

KamilCz
  • 93
  • 7