DEV Community

Discussion on: Making AJAX calls using the Fetch API

Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

Very nice post, but I don't quite understand why you would use $('#result') instead of document.querySelector('#result'); the first is quicker to write, but the latter is easier to understand and doesn't require loading jQuery to work.

same for $.each; it's 2019, we can just write [1, 2, 3, 4].each(console.log), no need for jquery whatsoever <3

Collapse
 
nikola profile image
Nikola Brežnjak

Ah, sorry, not sure how I missed this reply :(

Thank you for your comments, I agree.