I am working on a project using React.js and I have that errors using the eslint :
Do not nest ternary expressions
Here is my code :
const MyApp = () => {
return (
<>
{(var1 && var2) ? (
<Tag1 />
) : error ? (
<Tag2 />
) : null}
</>);
}
Do you know how can I do to solve that ? I tohught to use if but I think I cannot in my case ...