New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
next/image doesn't work but img jsx works #65232
Labels
bug
Issue was opened via the bug report template.
Image (next/image)
Related to Next.js Image Optimization.
locked
Comments
github-actions
bot
added
the
Image (next/image)
Related to Next.js Image Optimization.
label
May 1, 2024
import crossImage from '../public/cross.jpg';
<Image src={crossImage} height={876} width ={544} alt = 'image alt'/> You have to use this syntax for src prop. Don't put the |
ohk thanks this works, but previously that kind of path works for my older projects |
This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
bug
Issue was opened via the bug report template.
Image (next/image)
Related to Next.js Image Optimization.
locked
Link to the code that reproduces this issue
https://github.com/MikeyA-yo/bibleapp/blob/main/components/minimal-issue.tsx
To Reproduce
Current vs. Expected behavior
I get that error and no image rendered
Provide environment information
Which area(s) are affected? (Select all that apply)
Image (next/image)
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
normal img jsx works with the code solution above and renders the image that's what i'm using now, but i just decided to help file this bug report for the sake of optimization and more features from next/image
The text was updated successfully, but these errors were encountered: