Skip to content

Instantly share code, notes, and snippets.

@av1d
Last active November 22, 2025 04:35
Show Gist options
  • Select an option

  • Save av1d/012861034f14c1b10bc7552bed40f11f to your computer and use it in GitHub Desktop.

Select an option

Save av1d/012861034f14c1b10bc7552bed40f11f to your computer and use it in GitHub Desktop.
Amazon Wishlist Black Friday filter

Paste this in your browser's console. (CTRL+SHIFT+i)

Run this to simulate scrolling (wishlist uses progressive loading bullshit):

let lastScroll = -1;
let checkScroll = setInterval(function() {
  window.scrollTo(0, document.body.scrollHeight);
  if (window.scrollY === lastScroll) {
    clearInterval(checkScroll);
    console.log("Scrolling complete.");
  }
  lastScroll = window.scrollY;
}, 750);

Once loaded, run this to stop the scrolling:

clearInterval(checkScroll);

Finally, hide everything that isn't on sale:

document.querySelectorAll('.awl-ul-item-container-desktop').forEach(function(item) {
  const hasDeal = item.querySelector('span.wl-deal-rich-badge-label, span')
    && Array.from(item.querySelectorAll('span')).some(
      span => span.textContent.trim() === "Black Friday Deal"
    );
  if (!hasDeal) {
    item.style.display = 'none';
  }
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment