Skip to content

Instantly share code, notes, and snippets.

Sagi Chizik sagic

Block or report user

Report or block sagic

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@sagic
sagic / wsapp-reply.js
Created Jan 24, 2017
reply to web whatsapp spammers
View wsapp-reply.js
// import/require jquery (or copy from cdn) and then:
var lastText = '';
$('.pane-chat .message-list').bind('DOMSubtreeModified',function(e){
var txt = $('.pane-chat .message-list .msg').last()[0].innerText;
if (lastText !== txt) {
lastText = txt;
// console.log(lastText);
if (lastText.indexOf('Yossi') > -1) { // search for an incoming message text
You can’t perform that action at this time.