In Ruby i can use return if variable != 1 as example to not run the code comming after the return. I need to do the same in JS but i dont want to use a full if (variable != 1) { My code here } statement. Is that possible?
return if variable != 1
if (variable != 1) { My code here }
Aucun commentaire:
Enregistrer un commentaire