π¨βπ» A Day in the Life of a Developer π©βπ»
Started out with a tiny fix-up to do on a legacy website and run into a wild bugπ: some of desktop menu items refused to show their pages! π€ Mobile menu? No problemo! π± Desktop menu β problemo! π΅οΈββοΈ
First stop: Admin panel. π οΈ Oh, desktop menu is missing some of the hrefs that the mobile menu has. Let’s put them in. All good now? No sir! π
Next up: diving into the code. Oh, the main menu template says if an item has children then this item does not get an <a href> tag. Is it supposed to be like this? Evidently not. Added those bad boys in. π» Easy fix, or so I thought. π¬
The correct hrefs are now in place! But… click on them β nothing happens. Why? π±
Turns out, the old jQuery code overrides the clicks! π€¦ββοΈ Do I want to mess with this legacy beast? Care to wake the dragon? π
Is there a way around? Let’s see if we can restructure the HTML. Does not work the first time… but works the second time! Tested and retested across desktop and mobile β voilΓ , it works like a charm! π©β¨
Thinking of R. Martin quoting his boss in Clean Coder book: “Bugs aren’t ‘interesting.’ They just have to be fixed.” Well, some bugs do have a hint of intrigue, but shh, don’t tell the boss! ππ€«