@eleswastaken
Posted
Good job!
img
tags are supposed to represent some kind of meaning, product, illustration... Whereas background images are solely for design purposes. So, I am not sure what would be the problem, there is no right solution, remember:)?
About the collapsibles, yes, there is such a thing called event delegation. But the use case would be for something much larger, say, a table 100x100. There it would be inefficient to loop through every cell, you could just listen to the container, and use the event.target
for logic. In your case I am positive there is no need for that.
Side note: For things like collapsibles it would be a lot better to use <details>
and <summary>
tags. They have a semantic meaning and are accessible.
Good luck!
Marked as helpful
@olesiakissa
Posted
@eleswastaken Thank you for the advices! I'll make sure to check out those tags.
I was thinking that the <button>
s would be okay because they are focusible but your suggestion on <details>
& <summary>
tags is really great.
Have a nice day! :)