I have the below code in a website and I need to change the "Getting Started" text
<h4 data-v-318a1596="" class="h4">
<div data-v-318a1596="">
<i data-v-318a1596="" class="fa fa-check-square-o" style="color: rgb(141, 153, 166); font-size: 18px; margin-right: 6px;"></i>
Getting Started
</div>
</h4>
As I have read here I tried to use textContent
as below;
document.getElementsByClassName('h4')[0].childNodes[0].textContent='My text here'
The above code replaces the text but it also replaces the other HTML part specifically below;
<i data-v-318a1596="" class="fa fa-check-square-o" style="color: rgb(141, 153, 166); font-size: 18px; margin-right: 6px;"></i>
So after running my code the source looks like below;
<h4 data-v-318a1596="" class="h4"><div data-v-318a1596="">My text here</div></h4>
Could you please help me to replace only the text part?