
Day 02 JS and DOM
Flashcard
•
Science
•
University
•
Practice Problem
•
Hard
Aymane Benhima
FREE Resource
Student preview

11 questions
Show all answers
1.
FLASHCARD QUESTION
Front
Quel type de node représente un élément HTML ?
Back
Node.ELEMENT_NODE
2.
FLASHCARD QUESTION
Front
Quelle méthode retourne le premier élément correspondant à un sélecteur CSS ?
Back
document.querySelector()
3.
FLASHCARD QUESTION
Front
Quelle propriété donne accès à l'élément du document ?
Options: document.head, document.body, document.html, document.root
Back
document.body
4.
FLASHCARD QUESTION
Front
Comment change-t-on la couleur d'un élément en rouge via JavaScript ?
Back
element.style.color = "red"
5.
FLASHCARD QUESTION
Front
Comment récupère-t-on la valeur d'un attribut "data-id" ?
Back
element.getAttribute('data-id')
6.
FLASHCARD QUESTION
Front
Comment ajoute-t-on une classe "active" à un élément ?
Back
element.classList.add("active")
7.
FLASHCARD QUESTION
Front
Complétez la sélection de tous les éléments avec la classe "item" :
Back
querySelectorAll
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?