how to get element by classanem first item js code example
Example: js get first element by class
var elements = document.getElementsByClassName('className');
var requiredElement = elements[0];
var elements = document.getElementsByClassName('className');
var requiredElement = elements[0];