I've been encountering some challenges with a piece of code and haven't been able to make it function as intended. I'm relatively new to JavaScript/jQuery, so bear with me as I navigate through this learning process.
As part of the Free Code Camp course, I am working on creating a Weather App using simpleWeather.js. I'm currently attempting to add some animation to the page to enhance interactivity. Here is the code snippet I'm using:
$('#drop').on('click', function() {
$('.fa-chevron-circle-down').css('transform', 'rotate(180deg)');
});
My understanding is that this code should rotate the icon 180 degrees upon a click event, but despite multiple attempts, I have not been successful. After spending hours troubleshooting yesterday, I decided it was time to seek assistance! (Once this functionality is achieved, my plan is to animate the elements below so they are only displayed when the button is clicked).
For reference, my codepen can be found here.
Thank you in advance for any guidance or support provided.