Check out example codes for "javascript async fetch file html". It will help you in understanding the concepts better.

Code Example 1

async function () {
element.innerHTML = await (await fetch('./filetofetch.html')).text();
}

Learn ReactJs, React Native from akashmittal.com