Skip to content

Instantly share code, notes, and snippets.

@coolshaurya
coolshaurya / reloadForever.html
Last active August 10, 2018 11:28
Forever reloading page
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>This Will Reload Forever</title>
</head>
<p style="display: none">
const ageSpan = document.querySelector("#age");
const birthDate = new Date("17 September 2000");
const today = new Date();
if (today.getMonth() > birthDate.getMonth() && today.getDate() > birthDate.getDate()) {
ageSpan.innerText = today.getFullYear() - birthDate.getFullYear();
} else {
ageSpan.innerText = (today.getFullYear() - birthDate.getFullYear()) - 1;
}
<!DOCTYPE html>
<html>
<head>
<title>GET WORK DONE !!</title>
<style>
main{
position:absolute;
bottom:30%;
left:15%;
font-size:50px;