Last active
September 6, 2022 22:18
-
-
Save dsect/55d42cc3d952d38bf7c6537767de8cf7 to your computer and use it in GitHub Desktop.
TamperMonkey script for clipping ShopRite.com online coupons
This file contains hidden or 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
| // ==UserScript== | |
| // @name coupons.shoprite.com | |
| // @namespace http://tampermonkey.net/ | |
| // @version 0.1 | |
| // @description try to take over the world! | |
| // @author You | |
| // @match https://shop-rite-web-prod.azurewebsites.net/ | |
| // @grant none | |
| // @require http://code.jquery.com/jquery-3.3.1.min.js | |
| // ==/UserScript== | |
| var $ = window.jQuery; | |
| $(document).ready(function () { | |
| setTimeout(function () { clipCoupons(); }, 6000); | |
| function clipCoupons() { | |
| $(".available-to-clip").each(function (i, obj) { | |
| //console.log(i, obj); | |
| $(this)[0].click() | |
| // if (!$(this).hasClass("ng-hide")){ | |
| // angular.element(this).triggerHandler('click'); | |
| // console.log($(this).hasClass("ng-hide")); | |
| // } | |
| //else { | |
| // console.log('Hidden!'); | |
| //} | |
| }); | |
| }; | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment