react-exif-orientation-img
react-exif-orientation-img copied to clipboard
Question: onLoad not working?
I pass onLoad to the component, but it does not work. Curious if this is passed through to the underlying img component?
Using like this:
import Img from "react-exif-orientation-img";
...
return (
<Box>
<Img
style={{ maxWidth: "100%", maxHeight: "100%", display: "block" }}
className="EntryImage"
src={finalURL}
alt="url"
onLoad={event => {
console.log("Image loaded", event);
}}
/>
</Box>
);
I have done the onLoad function before with jquery but you will not need to link jquery to your html.
$(document).ready(function(){ $("#exampleModal").modal("show"); });
Sorry i can't explain how it work but it is easy to figure out, for more help click over here.
looking at my code will help you figure it out.