From ece2b67aa689aee0b881bac17a62c16e0469bc56 Mon Sep 17 00:00:00 2001 From: Matthew Kosarek Date: Sun, 21 Feb 2021 18:32:04 -0500 Subject: Proper support for favicons, rigid body intersections are no longer broken, palinko game --- frontend/index.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'frontend/index.js') diff --git a/frontend/index.js b/frontend/index.js index 0cbd896..f481bc6 100644 --- a/frontend/index.js +++ b/frontend/index.js @@ -1,10 +1,10 @@ /// -function main() { - console.log('Document ready.'); - const lPathName = window.location.pathname.length > 1 && window.location.pathname.startsWith('/') ? window.location.pathname.substr(1) : window.location.pathname; - console.log(lPathName); - $('nav').find('a[href="' + lPathName + '"').addClass('nav-selected'); -} - -$(document).ready(main); \ No newline at end of file +(function() { + function main() { + const lPathName = window.location.pathname.length > 1 && window.location.pathname.startsWith('/') ? window.location.pathname.substr(1) : window.location.pathname; + $('nav').find('a[href="' + lPathName + '"').addClass('nav-selected'); + } + + $(document).ready(main); +})() \ No newline at end of file -- cgit v1.2.1