RafidMuhymin / astro-imagetools

Image Optimization tools for the Astro JS framework

Home Page:astro-imagetools-docs.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[BUG] .JPG photo format not being recognized

OlshaMB opened this issue · comments

I am getting this error in the console:
Error
here is how ask for an image:

await renderImg({
  src: process.cwd()+"/"+path,
  alt: "My photo",
  breakpoints: {
     maxWidth: 5000
  }
})

where path is something like this "src/pages/photos/photo.JPG"

My guess is that astro thinks the extension of the file is .33333333333333 - incorrect,
i renamed .JPG file to .jpeg format and now everything works

So i think importer is not registered for JPG and caps names.

Sounds like a duplicate of the issue #129 I filed

I think i have similar issue:
[Error: Input file has corrupt header: VipsForeignLoad: "C:\www\2023\test\node_modules\.cache\astro-imagetools\e8906cb402b79d079b52db501ada860c.jpg" is not a known file format]

but it's always after generate about 700 first images. There is any option for fetch delay to remote images?