Skip to content

使用Puppeteer快速导出QQ阅读的内容到TXT内 Quickly export the content of book.qq.com (QQ Reading) to TXT by using puppeteer 微信读书太难导出了 不妨试试平替QQ阅读🤓

License

Notifications You must be signed in to change notification settings

aquamarine5/QQBookExporter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

QQBookExporter

wakatime

Setup

pnpm i

Tip

如果不使用 pnpm ,也可输入以下命令来安装依赖。

npm i

Note

QQBookExporter 使用 puppeteer-core 并默认指向 Windows 上的 Edge 浏览器,可以自行更改 executablePath 来指定浏览器。

如何使用?

node exporter.js <bid> [<ignore-chapters>] [<output-dir>]
  • bid: QQ阅读BookID,如:https://book.qq.com/book-detail/53350666bid 即为 53350666
  • ignore-chapters: 忽略抓取页面的cid值,以,分隔,或输入-取空值
  • output-dir: 输出路径

Example

node exporter.js 53350666 1,2 output
  • 首先,puppeteer会打开 https://book.qq.com/book-detail/53350666 页面,用户在此页面进行账号登录,以抓取收费内容。
  • 登录完成后,关闭当前选项卡页,随后 QQBookExporter 会自动开始抓取电子书内容并以TXT格式保存在 output\${chapter-index}-${chapter-name}.txt 下。
  • 因为 ignore-chapters 设置为 1,2 ,并不会捕捉第一第二章节(封面、版权内容)

image.png
输出文件目录

LICENSE

  • QQBookExporter 通过 LGPLv2.1 进行开源。
  • QQBookExporter 与 QQ阅读(book.qq.com)无关。

About

使用Puppeteer快速导出QQ阅读的内容到TXT内 Quickly export the content of book.qq.com (QQ Reading) to TXT by using puppeteer 微信读书太难导出了 不妨试试平替QQ阅读🤓

Topics

Resources

License

Stars

Watchers

Forks