About this video
Keeping the copyright year up to date is a simple bit of code but what is actually happening? We break down the JavaScript line-by-line in Webflow to understand this. You Might Not Need jQuery: http://youmightnotneedjquery.com/ IIFE Explanation: https://stackoverflow.com/questions/24930807/jquery-best-practice-using-document-ready-inside-an-iife jQuery Documentation: https://api.jquery.com/ Webflow (Affiliate Link): https://bit.ly/2ZzlJnd (function($) { var todaysYear = new Date().getFullYear() var $dateEl = $('.year') $dateEl.text(todaysYear) })(jQuery) Intro: (0:00) The Setup: (1:04) My Stance on jQuery/JavaScript: (1:56) What is an IIFE: (5:57) Where to Load JavaScript: (6:50) JavaScript in the Browser: (7:13) Getting Elements with jQuery: (8:49) Changing Text with jQuery: (10:54) jQuery Documentation: (11:37) Var, Let, Const: (14:53) Getting the Current Year: (17:52) Putting it All Together: (20:33) Recap: (22:08) Outro: (24:53) - Get to know me! Instagram: @fakesamgregory X: https://x.com/@0x5am5 - #Webflow #JavaScript #jQuery