Answer the question
In order to leave comments, you need to log in
Why does a button created with a styled component only fire 2 times?
Why does a button created with a React styled component only fire 2 times? default button works immediately here is the button creation code
const SendButton = styled.button`
z-index:100;
background:orangered;
margin: 0 auto;
border: none;
font-size: 20px;
padding: 5px 10px;
color: white;
&:hover {
cursor:pointer;
}
&:focus {
outline: none;
}
`;
Answer the question
In order to leave comments, you need to log in
Кр4 this button code needs to be pulled out of the functional component and everything will work correctly
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question