#Images not working after build (ASTROWIND)

1 messages · Page 1 of 1 (latest)

clever oasis
#

Images not working after build (ASTROWIND)

eternal lance
#

If you start your path with a /, Astro will look in the public/ folder.
For assets, the path to your images should be relative, like ../../assets/images/blog/xxxxxx.png
And to avoid issues with how many levels up you have to go, you can simply define an alias, so you can use something like: @assets/images/blog/xxxxxx.png
https://docs.astro.build/en/guides/typescript/#import-aliases

Docs

Learn how to use Astro's built-in TypeScript support.