directus / v8-archive

Directus Database API — Wraps Custom SQL Databases with a REST/GraphQL API

Home Page:https://docs.directus.io/api/reference.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to load images dynamically into angular application via directus sdk?

tieftontier opened this issue · comments

Hi guys,

I have a directus collection that contains images.
Via directus sdk I can

  • log in
  • find the collection
  • get the path to the image.

If I want to display this image in my angular application I currently use:
<img class="images" src={{DirectusImagePath}}>

My problem is that I can not load the image this way as I get a "403 (Forbidden)" exception.

What is the correct way to do this, when I need to dynamically load images from directus into my angular web app?

Any help is greatly appreciated! Thanks a lot in advance!
Tom