As the title says, my png image shows fine on markdown preview on VS Code, but when I actually run the server, the image won’t render. It only shows the temporary text, and when I try to open the image in a new tab via right clicking, it returns a 404 error.
I think this may be a bug since, as I previously mentioned, on VS Code the image shows fine without any problems. So I think that means the problem is not the directory, but something with the compiler or the renderer. Unless there is something that I don’t know?
Regardless, I’ve tried too google and fix it myself by
- changing the image directory from static to static/images
- changing the image directory to local(where the markdown post is)
- using the
{{ $image := .Resources.GetMatch "image.png" }}
(yes, I changed the image name)
with no change in results.
I would like to attach screenshots, but it is a post with semi-advertising(it’s about a game asset that I made), so I thought people wouldn’t like it. but I will if anyone finds it necessary.
(edit: temporary github repo is GitHub - whatthesamuel/hugo_website: hugo website code)
Using the PaperMod theme, but I don’t think it is a theme-related issue.
happens in hugo version 0.96.0
hugo v0.96.0-2fd4a7d3d6845e75f8b8ae3a2a7bd91438967bbb windows/amd64 BuildDate=2022-03-26T09:15:58Z VendorInfo=gohugoio
GOOS="windows"
GOARCH="amd64"
GOVERSION="go1.18"
(edited to better fit getting help guidelines)