sprig
sprig copied to clipboard
Image metadata is deprecated?
Describe the bug
All games on Sprig have a few metadata properties (i.e. @title, @author) and one of them is @img. After investigating some games that in the img property used "filename.png", I noticed the web browser make a call to /gallery/game.png. That however points to the gallery editor and the img itself. After looking more into the source code I located that the image source is now loaded via the already existing sprig API.
To Reproduce Steps to reproduce the behavior:
- Go to 'https://sprig.hackclub.com/gallery'
- Check Vercel/Console log
- Notice the error about
filename.png
Expected behavior The game img loads normally without any errors
Actual behavior
The game img loads normally but games with the specified @img tag point to bad path.
Solution The solution is rather easy:
- [ ] Remove the src attribute from the gallery.tsx
- [ ] Remove the `@img` tag from the template
- [ ] Edit metadata generate hook to not use `@img`
- [ ] Mass remove all mentions `@img` from games
Screenshots
If applicable, add screenshots to help explain your problem.