How obra/youtube2webpage works
The README describes a Perl command-line workflow that turns a YouTube URL into a local webpage with captions, video, and timestamped screenshots. The tree also contains an Electron application with a separate download-and-preview workflow. The Perl script itself was not excerpted, so its internal stages and calls are shown only as documented; the Electron IPC boundary is inferred from matching channel names and is dashed.
Main entry points: yt-to-webpage.pl Page generator · main_video_handling.js Video and captions · renderer.js Desktop UI · preload.js IPC bridge
Components 12
CLI generation
- Page generator
yt-to-webpage.pl - yt-dlp
- ffmpeg
- Generated webpage
Electron desktop
- Desktop UI
Youtube2Webpage/src/renderer.js - IPC bridge
Youtube2Webpage/src/preload.js - Electron main
Youtube2Webpage/src/main.js - Video and captions
Youtube2Webpage/src/main_video_handling.js - yt-dlp
- ffmpeg
Other components
- User
- Desktop user
Connections 10
- User → Page generator: runs with URL
README.md - Page generator → yt-dlp: uses
README.md - Page generator → ffmpeg: uses
README.md - Page generator → Generated webpage: creates
README.md - Desktop user → Desktop UI: uses
- Desktop UI → IPC bridge: invokes API
- IPC bridge → Electron main: IPC requests
- Electron main → Video and captions: calls
Youtube2Webpage/src/main.js - Video and captions → yt-dlp: runs
Youtube2Webpage/src/main_video_handling.js - Video and captions → ffmpeg: runs
Youtube2Webpage/src/main_video_handling.js