After reviewing a question on adding a hover class to an element, I am now curious about how to do the opposite.
I already have a main class for a button I am planning to create, where I will customize the background for each button using myButton.style.backgroundImage
. However, I also need to set up individual backgrounds for :hover for each unique button.
Is there a way to access the :hover pseudoclass through Javascript to apply the specific background?
Thank you in advance