mercredi 24 février 2021

Is there any better way to write blank if-else statements?

Is there a better way to write this logic without making it too complicated to read?

    if(event.key === 'Enter' && !carIsOpen){
      if(event.ctrlKey){
        // Do nothing
      }else {
        return;
      }
    }


Aucun commentaire:

Enregistrer un commentaire