| name | timeline-viewing |
| description | Switch between For You / Following timelines, auto-scroll and collect posts, scrape timeline data, and export as JSON. Use when users want to browse, collect, or export tweets from their X timeline. |
| license | MIT |
| metadata | {"author":"nichxbt","version":"1.0"} |
Timeline Viewing & Scraping
Browser console scripts for viewing, switching, and collecting posts from your X timeline.
Script Selection
| Goal | File | Navigate to |
|---|
| Switch timeline, auto-scroll, export posts | src/timelineViewer.js | x.com/home |
| Scrape timeline posts into structured data | src/timelineScraper.js | x.com/home |
Quick Start
- Go to
x.com/home
- Open DevTools (F12) → Console
- Paste
src/timelineViewer.js → Enter
- JSON file auto-downloads when complete
Configuration (timelineViewer.js)
const CONFIG = {
timeline: 'for-you',
autoSwitch: true,
collectPosts: true,
maxPosts: 100,
exportData: true,
scrollDelay: 2000,
delayBetweenActions: 1500,
maxScrollRetries: 8,
};
Available Functions
XActions.switchTo('for-you')
XActions.switchTo('following')
XActions.collect()
XActions.export()
XActions.abort()
XActions.scrape({ maxPosts: 200 })
XActions.results()
XActions.download()
Output Data Structure
Each collected post includes:
- Tweet ID, author, handle, avatar
- Tweet text, timestamp
- Likes, retweets, replies, views counts
- Media URLs (if any)
- Is retweet / is quote tweet
Notes
- Timeline data is only what's visible/scrolled in your browser session
for-you content is personalized; following shows only accounts you follow
- Increase
maxPosts for deeper scrapes (slower, more scroll rounds)
- Different from
twitter-scraping which targets specific profiles, not your feed
Related Skills
- twitter-scraping — Scrape a specific user's profile or tweet history
- analytics-insights — Analyze engagement metrics on your timeline
- discovery-explore — Find trending content beyond your timeline