Struggling to use collection of images in an image plot with Observable Framework #1925
Replies: 3 comments 2 replies
-
Hello, here https://observablehq.com/framework/lib/zip (in the second half of the page) is an example of working with such a collection of images. |
Beta Was this translation helpful? Give feedback.
-
oh shoot, I can't believe I stared at the right page but missed the example at the bottom. I'll check this out right away. |
Beta Was this translation helpful? Give feedback.
-
Ok, I think I got it. Thanks @Fil . I'll close this, but if there's anything in the code I did below that's still not quite the idiomatic approach I'd love to know if you have a moment to give feedback.
|
Beta Was this translation helpful? Give feedback.
-
I'd love to know what the experts suggest for making an image plot using locally hosted images.
I know in things like this https://observablehq.com/@observablehq/plot-image-dodge the images are being pulled by url from somewhere else, but when using framework if we have the images in the same project folder, is there a way to reference them?
I followed the archives suggestion https://observablehq.com/framework/data-loaders#archives and made a zip of the folder containing my images, and was able to demonstrate pulling one out with a literal string path, but I seem to be striking out when I try to create a url

FileAttachment
field for each element of my dataThe other thing I tried was just making url a string that followed the same pattern of formatting as the literal I confirmed was working, but I get 404's when I use those urls in the src field of the
Plot.image
function.Here's my snippet from the above screenshot in case it helps
Thanks so much!
Beta Was this translation helpful? Give feedback.
All reactions