Accessing static from endpoint #4355
Replies: 2 comments 3 replies
-
It should be possible to drop the domain part completely. If you just use |
Beta Was this translation helpful? Give feedback.
-
To be clear, the issue here is making a file (json, image, ...) available both in the assets so users can do The issue is though that while in development you could do ```js
This does feel wrong though, there must a better way. An alternative approach would be to not place the file in static but place it in 'lib/data' so we can do ```js
|
Beta Was this translation helpful? Give feedback.
-
Hi all!
I have an endpoint that uses images from the
static
folder and was wondering if there is a better practice for this.My current solution for the path of the image is as follows:
Is there a better way of doing this? any built-in features I am overlooking?
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions