Which approach is most recommended. First or Second ?
var x = document.querySelectorAll("span"); // #1: Console returns false x.length > 0 && x[0].blur(); // #2: Console returns undefined if (x.length > 0) { x[0].blur(); }
Aucun commentaire:
Enregistrer un commentaire