You've already forked konami-code-snippets
mirror of
https://github.com/hexolan/konami-code-snippets.git
synced 2026-05-20 03:29:22 +01:00
8c64c67c80
fix: library usage
22 lines
685 B
HTML
22 lines
685 B
HTML
<html>
|
|
<head>
|
|
<title>Konami Code Snippets</title>
|
|
</head>
|
|
|
|
<body>
|
|
<p>Konami Code - O(1)</p>
|
|
|
|
<sup>Note: currently just lower case `b` and `a` keys.</sup>
|
|
|
|
<sup>(as using <code>event.code</code> not deprecated <code>event.keyCode</code>)</sup>
|
|
|
|
<script src="https://cdn.jsdelivr.net/gh/hexolan/konami-code-snippets@main/src/core.min.js"></script>
|
|
<script>
|
|
function konamiCallback() {
|
|
window.location.href = `https://github.com/hexolan/konami-code-snippets`;
|
|
}
|
|
|
|
document.addEventListener("keydown", handleKonami(konamiCallback));
|
|
</script>
|
|
</body>
|
|
</html> |