1
Astro 7.1 (astro.build)
submitted 1 week ago by to c/astro@programming.dev
2
Astro 7.0 (astro.build)
submitted 1 month ago by to c/astro@programming.dev
3
4
Astro 6.4 released (astro.build)
submitted 2 months ago by to c/astro@programming.dev
5
Starlight 0.39 (astro.build)
submitted 2 months ago by to c/astro@programming.dev
6
Astro 6.2 released (astro.build)
submitted 2 months ago by to c/astro@programming.dev
 
 

Astro 6.2 introduces an experimental custom logger with JSON output, an SVG optimizer API, a new font file URL helper, and more.

7
8
9
10
Astro 6.1 is here (astro.build)
submitted 4 months ago by to c/astro@programming.dev
11
Astro 6.0 is here (astro.build)
submitted 4 months ago by to c/astro@programming.dev
12
13
 
 

So i try to make a Gallery with Astro and i hope someone can help me to grasp a few things.

I have a folder called "assets" in "src" in which all the images reside.

I also have a .astro file in "pages".
In this file i try to get the images with:

const images = import.meta.glob('/src/assets/*.{jpeg,jpg,png,gif}')  
const resolvedImages = Object.entries(images)  

in the body of the .astro i try to map "resolvedImages"

{resolvedImages.map((image) => (  
	<Image src={image[0]} alt="blabla" />  
))}  

Which kinda works but feels wrong. That i have to write "image[0]" instead of "image.src" can't be the solution.

There seems to be something called "ImageMetadata " , which has all the things i would like to have access to (filepath, width, etc.). But i don`t understand how to use it.

When i try

const images = import.meta.glob<ImageMetadata>('/src/assets/*.{jpeg,jpg,png,gif}')  

I still can´t access the values. What am i not understanding?

Also, is that even the right approach? There is also the option to define a collection and get that but the docs say those are just for markdown?

Thanks in advance.

14
15
Astro 5.17 released (astro.build)
submitted 5 months ago by to c/astro@programming.dev
16
17
Astro 6 Beta (astro.build)
submitted 6 months ago by to c/astro@programming.dev
18
2025 year in review (astro.build)
submitted 6 months ago by to c/astro@programming.dev
19
20
21
22
Astro 5.16 (astro.build)
submitted 8 months ago by to c/astro@programming.dev
23
24
Astro 5.15 (astro.build)
submitted 9 months ago by to c/astro@programming.dev
25
Astro 5.14 (astro.build)
submitted 10 months ago by to c/astro@programming.dev
view more: next ›