Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
52 lines (47 sloc) 968 Bytes
<!DOCTYPE HTML>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>WebPipe - the log streamer</title>
<style type="text/css">
*{
font-family: monaco, monospace;
}
html, body{
height : 100%;
min-height : 100%;
background : black;
color : #0F0
}
#container {
position : relative;
width : 100%;
height : 100%;
min-height : 100%;
overflow : hidden;
}
#log {
position : absolute;
bottom : 0;
left : 20px;
}
</style>
</head>
<body>
<div id="container">
<ol id=log></ol>
</div>
<script type="text/javascript">
(function(){
var logDiv = document.getElementById("log"),
source = new EventSource("/log");
source.addEventListener("message", function(e){
var data = e.data,
elt = document.createElement("li");
elt.insertAdjacentHTML("beforeend", data);
logDiv.appendChild(elt);
});
})();
</script>
</body>
</html>