It still has some advantages. If you do
const a = document.querySelector(`a`)
And then try to use a, it will throw an exception. With jQuery it just fails silently. This can be a pro or a con depending on your use case.
Also a good thing to use it for is when you receive a bunch of HTML in a string from a server and want to insert it into your document.
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
It still has some advantages. If you do
And then try to use a, it will throw an exception. With jQuery it just fails silently. This can be a pro or a con depending on your use case.
Also a good thing to use it for is when you receive a bunch of HTML in a string from a server and want to insert it into your document.