As we want to read it from top to bottom and avoid using variables, we need to heavily rely on ternary operators and logical expressions.
I can see why, with these (arbitrary?) requirements, JSX might look problematic. But I don't know why you're trying to force the use of ternary operators. Personally, I find the following formatting to be the most easy to read. And it doesn't require learning anything new.
({firstProgrammer,secondProgrammer,someCondition})=>{letinnerHtml;if(someCondition){if(firstProgrammer&&secondProgrammer){innerHtml=<p><bold>{firstProgrammer}</bold>, you're going to do pair-programming with {secondProgrammer}.</p>;}elseif(firstProgrammer&&!secondProgrammer){innerHtml=<p><bold>{firstProgrammer}</bold>, you'll code this task by yourself.</p>}else{innerHtml=<p>Hey man! Can you tell us your name before we give you job to do?</p>}}return<div>{innerHtml}</div>}
I can see why, with these (arbitrary?) requirements, JSX might look problematic. But I don't know why you're trying to force the use of ternary operators. Personally, I find the following formatting to be the most easy to read. And it doesn't require learning anything new.
yeah, I'm not going to argue here. In this case declaring local var makes more sense than ternary operators.