html
html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<html>
<head>
<style>
</style>
</head>
<body>
<h1>People entered:</h1>
<h2 id="count-el">0</h2>
<button id="increment-btn" onclick="increment()">increment</button>
<script src="index.js">
</script>
</body>
</html>
Enter to Rename, Shift+Enter to Preview
css
css
1
2
3
body {
}
Enter to Rename, Shift+Enter to Preview
js
js
1
2
3
4
5
6
7
8
9
10
11
let count = 0
countEl = document.getElementById("count-el")
console.log(countEl)
function increment() {
count = count + 1
countEl = count
console.log(countEl)
}
Enter to Rename, Shift+Enter to Preview
BROWSER
Console
Run