JS otrzyma pierwszy element po klasie

var elements = document.getElementsByClassName('className');
var requiredElement = elements[0];
Captain Obvious