How revuls/web-to-ai works
Web to AI Context is a Chrome extension that turns the active page into AI-ready Markdown. The popup requests extraction from the page script; that script clones the document, extracts readable article content, converts it to Markdown, and adds metadata. The popup estimates tokens and lets users copy or download the result, while keeping persistent local history for later copying or deletion. The main runtime flow is visible in the sampled scripts; the popup UI and extension configuration are included based on the README and file tree.
Main entry points: popup.js Popup Controller · content.js Page Extractor · popup.html Popup Controls · readability.js Article Extraction
Components 9
Popup Interface
- Popup Controls
popup.html - Popup Controller
popup.js
Page Processing
- Page Extractor
content.js - Article Extraction
lib/readability.js - Markdown Conversion
lib/turndown.js
Results and History
- System Clipboard
- Markdown Download
- Local History
popup.js
Other components
- Extension User
Connections 9
- Extension User → Popup Controls: opens
README.md - Popup Controls → Popup Controller: uses
README.md - Popup Controller → Page Extractor: requests extraction
popup.js - Page Extractor → Article Extraction: extracts article
content.js - Page Extractor → Markdown Conversion: converts content
content.js - Popup Controller → System Clipboard: copies Markdown
popup.js - Popup Controller → Markdown Download: downloads Markdown
popup.js - Popup Controller → Local History: reads and writes
popup.js - Extension User → Popup Controller: manages history
README.md