A simple solution to annoy anyone poking around your website.
Just put this in your .html file.
script src="https://cdn.jsdelivr.net/gh/terraegg/rrjs@latest/asciiPlayer.js">gt;script>gt;script>gt;new AsciiPlayer({autoPlay:1,loop:1}).loadAnimation('https://cdn.jsdelivr.net/gh/terraegg/rrjs@latest/data/ascii_animation.json')script>gt; npm install rrjsThen in your HTML:
script src="node_modules/rrjs/asciiPlayer.js">gt;script>gt;
script>gt;
const player = new AsciiPlayer({ autoPlay: true, loop: true });
player.loadAnimation('node_modules/rrjs/data/ascii_animation.json');
script>gt; Or with a bundler (Webpack/Vite):
import AsciiPlayer from 'rrjs';
const player = new AsciiPlayer({ autoPlay: true, loop: true });
player.loadAnimation('node_modules/rrjs/data/ascii_animation.json');If you decide you want to change out the ASCII art, edit in the following format:
{
"frame_count": 23,
"width_chars": 80,
"frames": [
{
"frame": 0,
"duration_ms": 100,
"ascii": [
"line 1 of ascii art",
"line 2 of ascii art",
"..."
]
},
...
]
}
}const player = new AsciiPlayer({
animationData: null,
frameDelay: 100,
autoPlay: true,
loop: true
});