Skip to content

mbh00/medium-publishers-js-snippet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 

Repository files navigation

Auto‑Scroller + JSON Exporter (For Medium Publications' Huge List Page)

A lightweight browser-based tool that scrolls through Medium's infinite‑loading publication lists, extracts all publication metadata, and lets you download everything as clean JSON—directly from your browser, no backend required.


🚀 Features

✔ Auto‑scroll until the page is fully loaded

The script scrolls intelligently and detects when Medium stops loading new content.

✔ Publication metadata extraction

From each publication card, the script gathers:

  • category
  • publication link
  • logo
  • banner
  • submission guidelines URL
  • guidelines title
  • guidelines description
  • last updated text
  • claps
  • responses

✔ JSON Export

Once scrolling stops, you click “Export JSON” and download a structured file you can use anywhere:

  • Vue.js / React apps
  • Laravel + InertiaJS frontends
  • MySQL / MongoDB imports
  • SEO / indexing workflows
  • AI datasets

🧩 Installation

This tool requires zero setup. You can run it:

Option A → As a Bookmarklet

  1. Copy the content of snippet.js
  2. Create a new bookmark in your browser
  3. Paste the code into the URL field
  4. Save → Click the bookmark whenever you are on a Medium list page

Option B → Via Browser Console (Recommended)

  1. Open the Medium page you want to scrape
  2. Press F12 → open the Console
  3. Paste the entire script from snippet.js
  4. Press Enter
  5. Two buttons will appear:
    • Start Auto Scroll
    • Export JSON

▶ Usage

  1. Visit the Medium list containing publications, e.g.:
https://medium.com/@MediumStaff/list/7c0ec8037e61
  1. Paste and run snippet.js in the console
  2. Click Start Auto Scroll
  3. The page scrolls until all publications are visible
  4. Click Export JSON to download publications.json

🧪 Sample Output

{
  "category": "Humor",
  "publicationName": "Another Fucking Publication",
  "publicationUrl": "https://medium.com/...",
  "logoUrl": "https://miro.medium.com/...",
  "bannerUrl": "https://miro.medium.com/...",
  "guidelinesUrl": "https://medium.com/...",
  "guidelinesTitle": "Submission Guidelines",
  "guidelinesDescription": "Updated July 25, 2025...",
  "lastUpdated": "Nov 13",
  "claps": 2200,
  "responses": 46
}

📝 Medium Article (Full Case Study)

A complete write‑up explaining:

  • the scraping challenges
  • how Medium loads elements dynamically
  • why headless browsers fail
  • how I built a Vue + Laravel frontend

👉 Read here


🛠 Technologies Used

  • Vanilla JavaScript
  • DOMParser
  • Blob API for downloads
  • Medium DOM reverse‑engineering
  • Intelligent scroll detection

🤝 Contributing

PRs, fixes, enhancements, and improvements to extraction logic are welcome.
If you find new patterns in Medium's DOM, feel free to submit a patch! And if you find this tools useful, show some love and star the project 😉


📜 License

MIT License — free to use, share, modify.


✨ Author

Built by Hyacinthe — full‑stack engineer & AI‑powered builder.
Profile: https://github.com/mbh00

Releases

No releases published

Packages

 
 
 

Contributors