Forked from callmeloureiro/comoSerChatoNoWhatsapp.js
Created
October 18, 2017 14:56
-
-
Save EdMarcus/985ad81bc7906c0a26fedc8d03872e32 to your computer and use it in GitHub Desktop.
Como fazer alguém te responder no whatsapp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var counter = 0; | |
var i = setInterval(function(){ | |
window.InputEvent = window.Event || window.InputEvent; | |
var d = new Date(); | |
var event = new InputEvent('input', {bubbles: true}); | |
var textbox = document.querySelector('#main > footer > div.block-compose > div.input-container > div.pluggable-input.pluggable-input-compose > div.pluggable-input-body.copyable-text.selectable-text'); | |
// Mensagem que será enviada | |
textbox.textContent = "Me responde!"; | |
textbox.dispatchEvent(event); | |
document.querySelector("button.compose-btn-send").click(); | |
counter++; | |
// Envia 100 mensagens, uma mensagem a cada segundo. | |
// Se quiser enviar sem limites da zueira (porque the zuera never ends), só remover essa condição hu3hu3. | |
if(counter === 100) | |
clearInterval(i); | |
console.log("Já enviei " + counter + ' mensagens.') | |
// 1000 = 1 segundo, tempo que será enviada cada mensagem. | |
}, 1000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment