Home >Web Front-end >JS Tutorial >You can directly use the $/$$ function for debugging in Firefox/Chrome/Safari_javascript skills

You can directly use the $/$$ function for debugging in Firefox/Chrome/Safari_javascript skills

WBOY
WBOYOriginal
2016-05-16 17:56:141117browse

Then I tested it in various browsers and found that it is available in Firefox/Chrome/Safari, but not in IE9/Opera.

$ is equivalent to document.getElementById
$$ is equivalent to document.querySelectorAll
Type $ in the chrome console, $$ is clear at a glance

These two functions are built-in with browser debugging tools.

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn