Skip to content

Instantly share code, notes, and snippets.

@lucascompython
Last active March 18, 2022 08:57
Show Gist options
  • Save lucascompython/a3bad22ea63a4b6169c6af03071b48aa to your computer and use it in GitHub Desktop.
Save lucascompython/a3bad22ea63a4b6169c6af03071b48aa to your computer and use it in GitHub Desktop.
This is a very simple typeracer-cheat
/* ==== Typeracer Cheat ==== */
//Paste this script into the developer console right before the race start
//Now you can press any key and it will enter the correct one
var arrSpan = document.querySelectorAll('[unselectable="on"]');
var fullSentence = '';
arrSpan.forEach(function (item) {
fullSentence += item.innerHTML;
});
var index = 0;
document.getElementsByClassName("txtInput")[0].addEventListener("keypress", function (e) {
e.preventDefault();
this.value += fullSentence[index++];
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment