<!DOCTYPE html>
<html>
<head>
<title>Text editor</title>
<style type="text/css">
* { box-sizing: border-box; }
html, body, textarea {
margin: 0; border: 0; padding: 0;
height: 100vh; width: 100vw;
}
textarea { top: 0; left: 0; margin-bottom: 2em; }
textarea, button { position: absolute }
button { display: block; bottom: 0; right: 0; }
</style>
<script type="text/javascript">
onload = function () {
document.querySelector("button").onclick =
() => eval(document.querySelector("textarea").value);
}
</script>
</head>
<body><textarea></textarea><button>go</button></body>
</html>