document.getElementsByTagName("body")[0].innerHTML= `<iframe id="testFrame" src=""+window.location.toString()+"" style="position: absolute; top:0; left:0; right:0; bottom:0; width:100%; height:100%;"> </iframe>`; setInterval(()=>{document.getElementById("testFrame").src=document.getElementById("testFrame").src},10000)
This script was obtained here: https://www.technipages.com/how-to-auto-refresh-chrome-tabs-without-an-extension
I wanted to paste it into my browser's dev tools console, but it gave a general warning about doing this, saying that pasting stuff into the dev tools console that you don't know what it does may be unsafe.
The goal of this script is to automatically refresh the page that the browser tab is on every 10 seconds. There is a link provided to the article that explains this in the link name as well as within the article itself.
All I am looking for is an expert with HTML & Java Script to take a quick look to see if there is anything malicious in this code. From what I can tell, it looks pretty safe. It does not seem to be opening a back door, listening on ports, or sending any data.