let element = document.getElementsByTagName("p");
element.innerText = "Hello World!";
const app = document.getElementById('app');
const change_app_text = (text) => app.innerText = text;
change_app_text('Text you want');
console.log(app.innerHtml) // => <div id="app">Text you want</div>