Skip to content
Advertisement

Tag: reactjs

Why is my React MUI component not showing?

I am trying to use the MUI drawer component alongside with React router to display a simple navbar on the left of the page. I am very new to react and am not sure what I am doing wrong as the code compiles fine. The other two pages “Signup” and “Login” are showing up fine. The way the project is

How to know if the input is Email or username

I’m trying to let the user sign in using email OR username, I already implemented the backend and it’s working fine using Postman, but I didn’t know how to implement it in the frontend, Login.jsx: My question is how to let the INPUT knows if the user is typing a username or an email and then act accordingly, or is

Functional component not updating DOM when updating state with useState

EDIT: Codepen is here https://codepen.io/mark-kelly-the-looper/pen/abGBwzv I have a component that display “channels” and allows their minimum and maximum to be changed. An example of a channels array is: In my component, I send in the channels array as props, copy it to a channels object which uses useState, render the channels data, and allow a user to change a value

Advertisement