0

My navbar is showing error when I click menu but it's working in PC. Could you tell me why .

https://code.sololearn.com/Wa25A10a21a1/?ref=app

22nd Apr 2021, 10:07 AM
𝗣𝗮𝘄𝗮𝗻 𝗞𝘂𝗺𝗮𝗿 🅟︎🅚︎
𝗣𝗮𝘄𝗮𝗻 𝗞𝘂𝗺𝗮𝗿 🅟︎🅚︎ - avatar
3 Answers
+ 2
Thanks 😊 brother now it working
22nd Apr 2021, 2:18 PM
𝗣𝗮𝘄𝗮𝗻 𝗞𝘂𝗺𝗮𝗿 🅟︎🅚︎
𝗣𝗮𝘄𝗮𝗻 𝗞𝘂𝗺𝗮𝗿 🅟︎🅚︎ - avatar
+ 1
Try removing window onload(){..} function cause the task performs after window querySelector making it undefined. This is what I figured out.
22nd Apr 2021, 11:41 AM
Aditya
Aditya - avatar
+ 1
Pawan Kumar When you call function from an element then don't write function inside window.onload function
22nd Apr 2021, 11:54 AM
A͢J
A͢J - avatar