<div class="text">text1</div>
<div class="text">text2</div>
<div class="text">text3</div>
<select name="" id="select">
<option value="text1">text1</option>
<option value="text2">text2</option>
<option value="text3">text3</option>
</select>
const array = Array.from(document.getElementsByClassName('text')).map(len => len.innerHTML),
select = document.getElementById('select');
select.innerHTML = `${array.map(el => '<option>' + el + '</option>').join('')}`;