In this lesson, we learn how to target specific states of elements and apply styles only when those states are triggered. <p class="mb-4"> I am a <a class="text-purple hover:text-orange focus:bg-yellow" href="#">t
For a menu item, when we tab onto it, we want this element get 'focus' event, so that the submenu will show up. In the post, we will see how to achieve it by using JS+css, we will also see how to use 'nextElementSibling' to only focus the elemnt has