Files
rrx-downloader/README.md

30 lines
655 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# rrx_resource
## Requirements
- Node.js 18+
- Playwright: `npm install playwright`
## Usage
### Default workflow
```bash
node run.mjs "https://h5.rrx.cn/storeview/<page-id>.html"
```
### Remote Chrome DevTools (optional)
```bash
node run.mjs "https://h5.rrx.cn/storeview/<page-id>.html" --cdp http://127.0.0.1:9222
```
Or set:
```bash
export ENV_CDP=http://127.0.0.1:9222
```
## Output
- Screenshot: `downloads/<date>-<title>-<page-id>/index.png`
- Media files: `downloads/<date>-<title>-<page-id>/media/`
- Source URLs: `downloads/<date>-<title>-<page-id>/urls.txt`
## Notes
- Viewport: 375×667 @ dpr 3
- Only audio/video/image URLs are collected