Skip to content

Commit

Permalink
I made a subpage!!!!!!!
Browse files Browse the repository at this point in the history
  • Loading branch information
WiktorProj committed Jul 19, 2024
1 parent 35cbb4d commit a3d05fe
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions js_examples/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<!DOCTYPE html>
<html>
<body>
<h1><span id="random"></span> JS Examples <span id="random2"></span></h1>
<ol>
<li>
<h2>Random Characters</h2>
Here's the code:
<hr>
const r = [document.getElementById("random"), document.getElementById("random2")];
setInterval(() => {
r.forEach(i => {
i.innerHTML = String.fromCharCode(Math.floor(Math.random()*512));
});
},25)
<hr>
It does this:
<span id="random3"></span>
</li>
</ol>
</body>
<head>
<title>
JS Examples
</title>
<style>
* {
font-family: Consolas;
}
</style>
<script>
const r = [document.getElementById("random"), document.getElementById("random2"), document.getElementById("random3")]
setInterval(() => {
r.forEach(i => {
i.innerHTML = String.fromCharCode(Math.floor(Math.random()*512))
});
},25)
</script>
</head>
</html>

0 comments on commit a3d05fe

Please sign in to comment.