What is the Twig equivalent of the below PHP ternary condition?
<?php echo (isset($myVar) && !empty($myVar)) ? $myVar : '#button-cart'; ?>
I have ingloriously tried this but it doesn't look good and of course, it doesn't work:
{{ myVar is defined and myVar not empty ? myVar : '#button-cart' }}