Skip to content

Instantly share code, notes, and snippets.

@CanXploit
Created January 17, 2026 10:29
Show Gist options
  • Select an option

  • Save CanXploit/ca37fbd6210693ab27477ea31dfe7e83 to your computer and use it in GitHub Desktop.

Select an option

Save CanXploit/ca37fbd6210693ab27477ea31dfe7e83 to your computer and use it in GitHub Desktop.
Auto type hack speed on typeracer.com 430 WPM !!
var container = document.querySelector('table.inputPanel div > div');
var words = [];
if (container) {
let fullText = '';
container.querySelectorAll('span').forEach(span => {
fullText += span.textContent;
});
words = fullText.trim().split(/\s+/);
}
var input = document.querySelector('input.txtInput');
function typeWithSpace(index) {
if (index >= words.length) {
console.log('catch all words');
return;
}
input.value = words[index];
input.dispatchEvent(new Event('input', { bubbles: true }));
input.dispatchEvent(new Event('change', { bubbles: true }));
if (index < words.length - 1) {
setTimeout(() => {
input.value = words[index] + ' ';
input.dispatchEvent(new Event('input', { bubbles: true }));
let spaceEvent = new KeyboardEvent('keydown', {
key: ' ',
code: 'Space',
keyCode: 32,
bubbles: true
});
input.dispatchEvent(spaceEvent);
// change the timout for controll speed type
setTimeout(() => typeWithSpace(index + 1), 100);
}, 150);
} else {
console.log('last word');
}
}
if (words.length > 0 && input) {
input.focus();
typeWithSpace(0);
} else {
console.log("i can't find any text");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment