Skip to content

uupers/save-tieba

Repository files navigation

Tieba => Markdown

Site LICENSE LICENSE

保存贴吧的精品文章, 转化为 markdown 格式.

Tutorial

使用 npmyarn 安装

yarn add @vutex/wapp2md
npm install @vutex/wapp2md

然后输入帖子 id 就能下载并转换为 markdown 文件了.

import { writeFileSync } from 'fs'
import { parserPage } from '@vutex/wapp2md'
parseTiezi(5544838611).then($ => { writeFileSync(`${__dirname}/5544838611.md`, $) })

网页: http://tieba.baidu.com/p/5544838611

脚本: https://github.com/uupers/save-tieba/blob/master/projects/wapp2md/test/page.ts

效果: https://github.com/uupers/save-tieba/blob/master/projects/wapp2md/test/5544838611.md

获取贴吧精品编号:

parseTieba('数学').then($ => { writeFileSync(`${__dirname}/数学吧.json`, JSON.stringify($, null, 4)) })

效果: https://github.com/uupers/save-tieba/blob/master/projects/wapp2md/test/数学吧.json

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published