<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Salman Kabir</title>
    <description>The latest articles on DEV Community by Salman Kabir (@sksshouvo).</description>
    <link>https://dev.to/sksshouvo</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1215015%2Fc481a50c-d588-427f-908f-9a81ff90e071.jpg</url>
      <title>DEV Community: Salman Kabir</title>
      <link>https://dev.to/sksshouvo</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/sksshouvo"/>
    <language>en</language>
    <item>
      <title>Automating Facebook “Cancel Request / Unfollow” Using Pure JavaScript</title>
      <dc:creator>Salman Kabir</dc:creator>
      <pubDate>Wed, 14 Jan 2026 07:29:14 +0000</pubDate>
      <link>https://dev.to/sksshouvo/automating-facebook-cancel-request-unfollow-using-pure-javascript-1b83</link>
      <guid>https://dev.to/sksshouvo/automating-facebook-cancel-request-unfollow-using-pure-javascript-1b83</guid>
      <description>&lt;p&gt;Below is the &lt;strong&gt;same dev.to post rewritten strictly using the markdown syntax you specified&lt;/strong&gt;.&lt;br&gt;
You can copy–paste this directly into &lt;strong&gt;dev.to&lt;/strong&gt;.&lt;/p&gt;


&lt;h1&gt;
  
  
  Automating Facebook “Cancel Request / Unfollow” Using Pure JavaScript
&lt;/h1&gt;

&lt;p&gt;Facebook does not provide a native way to bulk cancel follow requests or unfollow users. When the following list becomes large, manually clicking &lt;strong&gt;Cancel request&lt;/strong&gt; one by one is inefficient and error-prone.&lt;/p&gt;

&lt;p&gt;This post explains how to automate the process using &lt;strong&gt;pure JavaScript&lt;/strong&gt; executed directly in the browser console — no extensions, no APIs, and no third-party libraries.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/sksshouvo/facebook-auto-unfollow-cancel-request-script" rel="noopener noreferrer"&gt;GitHub Repository&lt;/a&gt;&lt;/p&gt;


&lt;h2&gt;
  
  
  Problem Statement
&lt;/h2&gt;

&lt;p&gt;Facebook’s UI presents several challenges:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Infinite scrolling&lt;/li&gt;
&lt;li&gt;Obfuscated and frequently changing CSS class names&lt;/li&gt;
&lt;li&gt;Dynamically loaded DOM elements&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Because of this:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Static selectors break easily&lt;/li&gt;
&lt;li&gt;Automation must be DOM-aware&lt;/li&gt;
&lt;li&gt;Clicking too fast may trigger temporary restrictions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The objective was to create a script that is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Stable&lt;/li&gt;
&lt;li&gt;Rate-limit friendly&lt;/li&gt;
&lt;li&gt;Resilient to DOM changes&lt;/li&gt;
&lt;li&gt;Easy to stop safely&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  Solution Overview
&lt;/h2&gt;

&lt;p&gt;The script uses a &lt;strong&gt;two-phase strategy&lt;/strong&gt;.&lt;/p&gt;
&lt;h3&gt;
  
  
  Phase 1: Scroll to the End
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Scrolls until no new data loads&lt;/li&gt;
&lt;li&gt;Detects the true end by tracking document height&lt;/li&gt;
&lt;li&gt;Prevents infinite scrolling loops&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;
  
  
  Phase 2: Cancel Requests from Bottom to Top
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Collects all &lt;strong&gt;Cancel request / Unfollow&lt;/strong&gt; buttons&lt;/li&gt;
&lt;li&gt;Processes them from bottom → top&lt;/li&gt;
&lt;li&gt;Clicks one button every &lt;strong&gt;5 seconds&lt;/strong&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This approach avoids DOM reflow issues and ensures no request is skipped.&lt;/p&gt;


&lt;h2&gt;
  
  
  Why Bottom to Top Works Better
&lt;/h2&gt;

&lt;p&gt;When Facebook removes an item from the list:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The DOM reflows&lt;/li&gt;
&lt;li&gt;Element positions shift&lt;/li&gt;
&lt;li&gt;Indexes change dynamically&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Processing from bottom to top ensures:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Already-processed items are not affected&lt;/li&gt;
&lt;li&gt;Buttons are not skipped&lt;/li&gt;
&lt;li&gt;DOM behavior remains predictable&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Bottom-to-top processing is significantly more reliable on infinite-scroll UIs.&lt;/p&gt;
&lt;/blockquote&gt;


&lt;h2&gt;
  
  
  Key Design Decisions
&lt;/h2&gt;
&lt;h3&gt;
  
  
  1. No CSS Class Selectors
&lt;/h3&gt;

&lt;p&gt;Facebook class names change frequently.&lt;br&gt;
Instead, the script relies on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;role="button"&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;aria-label&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Visible button text&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These attributes are far more stable.&lt;/p&gt;


&lt;h3&gt;
  
  
  2. Rate-Limit Friendly Execution
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;One action every &lt;strong&gt;5 seconds&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;No parallel clicks&lt;/li&gt;
&lt;li&gt;Human-like interaction pattern&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This reduces the likelihood of triggering Facebook’s abuse detection.&lt;/p&gt;


&lt;h3&gt;
  
  
  3. Manual Stop Support
&lt;/h3&gt;

&lt;p&gt;The script can be stopped at any time without refreshing the page.&lt;/p&gt;

&lt;p&gt;Run this in the console:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;window.__STOP_UNFOLLOW__ = true;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  How to Use
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Open Facebook in Chrome&lt;/li&gt;
&lt;li&gt;Navigate to &lt;strong&gt;Following&lt;/strong&gt; or &lt;strong&gt;Followers&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Open &lt;strong&gt;DevTools → Console&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Paste the script from the repository&lt;/li&gt;
&lt;li&gt;Keep the tab active&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;To stop execution:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Refresh the page
&lt;strong&gt;or&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Run the stop command shown above&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Full Script Source
&lt;/h2&gt;

&lt;p&gt;The latest maintained version of the script is available here:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/sksshouvo/facebook-auto-unfollow-cancel-request-script" rel="noopener noreferrer"&gt;facebook-auto-unfollow-cancel-request-script&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Always prefer the GitHub version, as Facebook UI changes frequently.&lt;/p&gt;




&lt;h2&gt;
  
  
  Limitations and Disclaimer
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;This is &lt;strong&gt;not an official Facebook tool&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Use at your own risk&lt;/li&gt;
&lt;li&gt;Do not run repeatedly in short timeframes&lt;/li&gt;
&lt;li&gt;Facebook may change its UI at any time&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This project is intended for &lt;strong&gt;educational and personal automation purposes only&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  Possible Improvements
&lt;/h2&gt;

&lt;p&gt;Future enhancements could include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Auto-handling confirmation dialogs&lt;/li&gt;
&lt;li&gt;Randomized delays&lt;/li&gt;
&lt;li&gt;Daily action limits&lt;/li&gt;
&lt;li&gt;Pause / resume functionality&lt;/li&gt;
&lt;li&gt;Batch processing for very large lists&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Contributions and suggestions are welcome.&lt;/p&gt;




&lt;h2&gt;
  
  
  Closing Thoughts
&lt;/h2&gt;

&lt;p&gt;This project demonstrates what can be achieved using:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Plain JavaScript&lt;/li&gt;
&lt;li&gt;Native DOM APIs&lt;/li&gt;
&lt;li&gt;Careful control flow&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;No browser extensions.&lt;br&gt;
No automation frameworks.&lt;br&gt;
No backend services.&lt;/p&gt;

&lt;p&gt;If you find this useful, consider starring the repository or adapting the script for your own automation needs.&lt;/p&gt;

</description>
      <category>automation</category>
      <category>javascript</category>
      <category>productivity</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>An open-source project by Python for Upwork Freelancers "RSS Feed Fetcher"</title>
      <dc:creator>Salman Kabir</dc:creator>
      <pubDate>Sun, 03 Dec 2023 14:21:35 +0000</pubDate>
      <link>https://dev.to/sksshouvo/rss-feed-fetcher-2k3n</link>
      <guid>https://dev.to/sksshouvo/rss-feed-fetcher-2k3n</guid>
      <description>&lt;p&gt;Hi there, &lt;br&gt;
&lt;em&gt;Oompa-Loompas&lt;/em&gt; of science. I have very little knowledge of Python. I want to learn more about Python by developing cool and fun software or console apps or projects. With this kind of idea, I started developing this software Called &lt;strong&gt;RSS Feed Fetcher&lt;/strong&gt;.&lt;/p&gt;
&lt;h2&gt;
  
  
  What it does?
&lt;/h2&gt;

&lt;p&gt;Users can fetch data from an &lt;strong&gt;RSS Feed&lt;/strong&gt; link over and over again within a certain period. Those who do freelancing on &lt;strong&gt;Upwork&lt;/strong&gt; will be able to set a &lt;strong&gt;Job Search&lt;/strong&gt; as an RSS Feed link and copy that then paste it into our software and click on start. Then it will notify you when it finds a new post.&lt;/p&gt;
&lt;h2&gt;
  
  
  How to use it?
&lt;/h2&gt;

&lt;p&gt;Just go to the &lt;strong&gt;GitHub&lt;/strong&gt; link that I have provided below and follow the steps. It's an open-source application so I would like to request you guys to fork or clone this project and make it better for the world.&lt;/p&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fassets.dev.to%2Fassets%2Fgithub-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/sksshouvo" rel="noopener noreferrer"&gt;
        sksshouvo
      &lt;/a&gt; / &lt;a href="https://github.com/sksshouvo/rss-feed-fetcher" rel="noopener noreferrer"&gt;
        rss-feed-fetcher
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      Rss Feed Fetcher is a software which can fetch rss feeds from any kind of rss feed links of xml version 2 and specially targeted freelancers from upwork. Also user can set an interval and interval type to refetch  rss feeds from same rss feed link.
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;RssFeedFetcher&lt;/h1&gt;
&lt;/div&gt;
&lt;p&gt;A simple CLI system for fetch feed from a Rss feed.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Requirements&lt;/h1&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Python 3.10&lt;/li&gt;
&lt;li&gt;python3-tk&lt;/li&gt;
&lt;li&gt;virtualenv or your favourite Python environment tool&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Get Started&lt;/h1&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Clone the repository&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;git clone git@github.com:sksshouvo/rssFeedFetcher.git&lt;/pre&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Checkout the develop branch&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;git checkout develop&lt;/pre&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Install Python and create or use a Python Environment with Python Version listed in requirements&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;python3.10 -m venv env&lt;/pre&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Activate Python3.10 environment&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-c1"&gt;source&lt;/span&gt; env/bin/activate&lt;/pre&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Install the local requirements&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;pip install -r requirements.txt&lt;/pre&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Run&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight highlight-source-shell notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;python main.pyw&lt;/pre&gt;

&lt;/div&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Branching Model&lt;/h1&gt;

&lt;/div&gt;
&lt;p&gt;We use a branching model similar to this site (&lt;a href="https://nvie.com/posts/a-successful-git-branching-model/" rel="nofollow noopener noreferrer"&gt;https://nvie.com/posts/a-successful-git-branching-model/&lt;/a&gt;).
When you work on a new task, please create a feature-branch ( &lt;strong&gt;feature/RFF-14-Feature-Title&lt;/strong&gt; ) from the ( &lt;strong&gt;develop&lt;/strong&gt; ) branch.
To publish any changes instead of direct push, create a &lt;strong&gt;PR&lt;/strong&gt; to &lt;strong&gt;develop&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;feature/RFF-###-Title&lt;/li&gt;
&lt;li&gt;develop&lt;/li&gt;
&lt;li&gt;release-#.#.#&lt;/li&gt;
&lt;li&gt;hotfix-#.#.#&lt;/li&gt;
&lt;li&gt;main&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;NOTE : WE BELIEVE IN MAINTAINING STANDARD.&lt;/h2&gt;

&lt;/div&gt;
&lt;p&gt;SO DON'T FORGET TO RUN AT LEAST &lt;code&gt;flake8&lt;/code&gt; AND &lt;code&gt;isort&lt;/code&gt; IN CHANGED FILE BEFORE ANY NEW COMMIT AND…&lt;/p&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/sksshouvo/rss-feed-fetcher" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;


&lt;h2&gt;
  
  
  Team members
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Ahasanul A Rijon (Github: &lt;a href="https://github.com/ahasanular" rel="noopener noreferrer"&gt;https://github.com/ahasanular&lt;/a&gt;)&lt;/li&gt;
&lt;/ol&gt;

</description>
      <category>python</category>
      <category>programming</category>
      <category>beginners</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
