Comment by Killed_Mufasa on 01/03/2025 at 12:27 UTC*
1 upvotes, 1 direct replies (showing 1)
View submission: React App Completely Unresponsive After Git Clone and npm Install
View parent comment
Thanks, that's helpful. Watched your vids, here are some thoughts:
- You nest a <button in a <a, that's generally not recommended. But if you do, make sure to make the type=button. As type=submit is the default.
- It looks like you're not using React devtools, you really should! It also has an element select thingy, you can check what is being rendered, with what props, etc.
- In your example I didn't see any event handlers applied, can you try if on onClick event on a button shows up in the DOM?
- Are any changes applied at all? The console.logs (make sure to put it in a useEffect with no dependencies = on mount) should really appear. Check with react dev tools which components are rendered.
- Use inspect element or react dev tools to inspect the contents of #root. Check if there is some kind of overlay with full height/width. Try deleting some stuff, to see if that makes a difference.
Replies
Comment by bycmlla at 01/03/2025 at 13:01 UTC
1 upvotes, 1 direct replies
Oh, thank you so much! I identified that there was a `z-index: -1` applied to my home, which I had no idea was causing all this trouble on my site. I'm now using React DevTools, which I wasn't using before because I was always using the Opera browser. But everything has been resolved. Thank you so much for your help!!!!