I'm currently working on my React app and trying to add effects to images when they appear on the page. I have tried using the code below, but it doesn't seem to work as expected. I directly applied styles to the div tag because I couldn't get trigger effects like hovering or clicking to work. Could it be that I am approaching this in the wrong way?
JSS styles
column: {
...
"& div": {
transition: "all 0.5s ease-in-out"
}
}
JSX
renderColumn(column) {
return column.map((item, i) => (
<div key={i}>
<img ... />
</div>
));
}