-1
I’m making a comparison logic within Classname, follows:
<button className={'OVERDUE' || 'CONFIRMED' || 'RECEIVED' === 'PENDING' ? 'YES' : 'NO'} onClick={ () => this.showModalEdit(payment)} >My button</button>
The problem with the code is that it always comes back YES.
I’m a little confused by what you tried to do. What was the expected behavior?
– Andre
You’re not comparing anything to variables. Assemble your logic into one
if
first and then try to put inclassName
, if you wish– Rafael Tavares