Add logging for document.querySelectorAll