Support srcset in CardMedia
See original GitHub issueCardMedia component doesn’t seem to support responsive images.
- This is a v1.x issue (v0.x is no longer maintained).
- I have searched the issues of this repository and believe that this is not a duplicate.
Expected Behavior
Should be able to pass in a srcset
attribute for image components in general.
Current Behavior
Not supported?
Issue Analytics
- State:
- Created 5 years ago
- Reactions:6
- Comments:7 (7 by maintainers)
Top Results From Across the Web
Support srcset in CardMedia · Issue #11675 · mui/material-ui
CardMedia component doesn't seem to support responsive images. This is a v1.x issue (v0.x is no longer maintained).
Read more >MUI: either `image` or `src` property must be specified
It's looks like CardMedia need an image ...
Read more >Srcset and sizes attributes | | Can I use... Support tables for ...
The srcset and sizes attributes on img (or source ) elements allow authors to define various image resources and "hints" that assist a...
Read more >How to properly use images in a responsive way : r/reactjs
What's CardMedia? Something from Material UI? No matter, check out image srcSet, or switch out images with CSS media queues.
Read more >Picture perfect images with the modern <img> element
Request your key hero image early; Use srcset + efficient modern image ... The <picture> element supports multiple <source> elements and a ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@adeelibr Thanks for sharing. I guess we can start experimenting with this workaround.
@kaycebasques Actually, it’s supported, you can use the
component
property to render an image over a div with a background image.