Register to get access to free programming courses with interactive exercises

DevTools JS: DOM API

DevTools is a powerful tool for debugging and analyzing what's happening on the page. Frontend development cannot be done without it. Modern browsers are already fully equipped with this useful tool, you just need to find it in the menu and activate it. And it's worth spending time and exploring the capabilities of DevTools. There are so many things that DevTools can be used for that this course simply isn't enough to study all its possibilities. The Internet is full of articles all about the most interesting ways to use DevTools, and its hidden features. So, we'll only go through the basic features here.

Error analysis

DevTools Stack Trace

All errors that occur in browser-based js are output to the console. You can not only view them, but also open the source code to see where the error appeared.

Selected item

After choosing an element in this way, you can go to the console tab and type $0. This is how you can get access to this element.

devtools element search

You can use the $() function to simplify the search for elements by selector. Compare:

document.querySelector('.row');

// Technically similar to working with jQuery, but it isn't jQuery
$('.row');

console.dir

devtools console.dir

The function console.dir outputs DOM nodes in a format that's convenient for analysis.


Hexlet Experts

Are there any more questions? Ask them in the Discussion section.

The Hexlet support team or other students will answer you.

About Hexlet learning process

For full access to the course you need a professional subscription.

A professional subscription will give you full access to all Hexlet courses, projects and lifetime access to the theory of lessons learned. You can cancel your subscription at any time.

Get access
130
courses
1000
exercises
2000+
hours of theory
3200
tests

Sign up

Programming courses for beginners and experienced developers. Start training for free

  • 130 courses, 2000+ hours of theory
  • 1000 practical tasks in a browser
  • 360 000 students
By sending this form, you agree to our Personal Policy and Service Conditions

Our graduates work in companies:

<span class="translation_missing" title="translation missing: en.web.courses.lessons.registration.bookmate">Bookmate</span>
<span class="translation_missing" title="translation missing: en.web.courses.lessons.registration.healthsamurai">Healthsamurai</span>
<span class="translation_missing" title="translation missing: en.web.courses.lessons.registration.dualboot">Dualboot</span>
<span class="translation_missing" title="translation missing: en.web.courses.lessons.registration.abbyy">Abbyy</span>
Suggested learning programs

From a novice to a developer. Get a job or your money back!

Frontend Developer icon
Profession
beginner
Development of front-end components for web applications
start anytime 10 months

Use Hexlet to the fullest extent!

  • Ask questions about the lesson
  • Test your knowledge in quizzes
  • Practice in your browser
  • Track your progress

Sign up or sign in

By sending this form, you agree to our Personal Policy and Service Conditions
Toto Image

Ask questions if you want to discuss a theory or an exercise. Hexlet Support Team and experienced community members can help find answers and solve a problem.