javaScript получить элемент от id
var element = document.getElementById("YourElementId");
Batman
var element = document.getElementById("YourElementId");
document.getElementById("someid");
const element = document.getElementById('id');
//or
const element = document.querySelector('#id');
let variableName = document.getElementById('#Id_name_you_gave_the_element');
// getElementById returns elements that have the id specified. Example:
document.getElementById("specificparagraph").style.color = "blue";
/* The element with the id "specificparagraph" will have its text changed to
blue. */
const element = document.getElementById('id');