rsshub 1.0.0-master.fb68956 → 1.0.0-master.fbabfc2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/config.js +1 -0
- package/lib/middleware/parameter.js +8 -1
- package/lib/middleware/template.js +29 -11
- package/lib/router.js +39 -39
- package/lib/routes/bandisoft/index.js +4 -0
- package/lib/routes/biobio/others.js +5 -0
- package/lib/routes/blogs/hedwig.js +4 -0
- package/lib/routes/blogs/wordpress.js +5 -0
- package/lib/routes/booth-pm/shop.js +4 -1
- package/lib/routes/craigslist/search.js +5 -0
- package/lib/routes/engadget/home.js +4 -0
- package/lib/routes/fanbox/main.js +4 -1
- package/lib/routes/fashionnetwork/headline.js +4 -0
- package/lib/routes/fashionnetwork/news.js +5 -0
- package/lib/routes/gitlab/common.js +5 -0
- package/lib/routes/gitlab/explore.js +5 -0
- package/lib/routes/gitlab/release.js +5 -0
- package/lib/routes/gitlab/tag.js +5 -0
- package/lib/routes/hexo/fluid.js +4 -0
- package/lib/routes/hexo/next.js +4 -0
- package/lib/routes/hexo/yilia.js +4 -0
- package/lib/routes/mastodon/account_id.js +4 -0
- package/lib/routes/mastodon/timeline_local.js +4 -0
- package/lib/routes/mastodon/timeline_remote.js +4 -0
- package/lib/routes/mastodon/utils.js +3 -0
- package/lib/routes/pornhub/category_url.js +4 -0
- package/lib/routes/pornhub/model.js +4 -0
- package/lib/routes/pornhub/pornstar.js +4 -0
- package/lib/routes/pornhub/users.js +4 -0
- package/lib/routes/touhougarakuta/index.js +3 -0
- package/lib/routes/weforum/report.js +10 -6
- package/lib/routes/ziroom/room.js +5 -0
- package/lib/utils/render.js +46 -0
- package/lib/utils/valid-host.js +16 -0
- package/lib/v2/18comic/album.js +2 -1
- package/lib/v2/18comic/blogs.js +2 -1
- package/lib/v2/18comic/radar.js +39 -29
- package/lib/v2/18comic/utils.js +6 -10
- package/lib/v2/19lou/index.js +4 -0
- package/lib/v2/91porn/author.js +2 -0
- package/lib/v2/91porn/index.js +2 -0
- package/lib/v2/91porn/utils.js +12 -0
- package/lib/v2/baai/comments.js +35 -0
- package/lib/v2/baai/events.js +35 -0
- package/lib/v2/baai/hub.js +60 -0
- package/lib/v2/baai/maintainer.js +5 -0
- package/lib/v2/baai/radar.js +31 -0
- package/lib/v2/baai/router.js +7 -0
- package/lib/v2/baai/utils.js +33 -0
- package/lib/v2/baidu/maintainer.js +1 -0
- package/lib/v2/baidu/radar.js +8 -0
- package/lib/v2/baidu/router.js +1 -0
- package/lib/v2/baidu/templates/top.art +9 -0
- package/lib/v2/baidu/top.js +34 -0
- package/lib/v2/bendibao/news.js +4 -0
- package/lib/v2/bioone/featured.js +10 -8
- package/lib/v2/bioone/journal.js +11 -8
- package/lib/v2/biquge/index.js +21 -0
- package/lib/v2/bitmovin/blog.js +15 -21
- package/lib/v2/bjp/apod.js +43 -0
- package/lib/v2/bjp/maintainer.js +3 -0
- package/lib/v2/bjp/radar.js +13 -0
- package/lib/v2/bjp/router.js +3 -0
- package/lib/v2/bjsk/index.js +52 -0
- package/lib/v2/bjsk/maintainer.js +3 -0
- package/lib/v2/bjsk/radar.js +13 -0
- package/lib/v2/bjsk/router.js +3 -0
- package/lib/v2/bjwxdxh/index.js +52 -0
- package/lib/v2/bjwxdxh/maintainer.js +3 -0
- package/lib/v2/bjwxdxh/radar.js +13 -0
- package/lib/v2/bjwxdxh/router.js +3 -0
- package/lib/v2/blockbeats/index.js +28 -35
- package/lib/v2/blockbeats/maintainer.js +1 -1
- package/lib/v2/blockbeats/radar.js +3 -3
- package/lib/v2/bloomberg/authors.js +52 -0
- package/lib/v2/bloomberg/index.js +1 -10
- package/lib/v2/bloomberg/maintainer.js +1 -0
- package/lib/v2/bloomberg/radar.js +9 -3
- package/lib/v2/bloomberg/router.js +1 -0
- package/lib/v2/bloomberg/utils.js +14 -2
- package/lib/v2/btzj/index.js +6 -1
- package/lib/v2/byteclicks/index.js +22 -0
- package/lib/v2/byteclicks/maintainer.js +4 -0
- package/lib/v2/byteclicks/radar.js +19 -0
- package/lib/v2/byteclicks/router.js +4 -0
- package/lib/v2/byteclicks/tag.js +30 -0
- package/lib/v2/byteclicks/utils.js +13 -0
- package/lib/v2/caixin/article.js +27 -0
- package/lib/v2/caixin/blog.js +58 -0
- package/lib/v2/caixin/category.js +56 -0
- package/lib/{routes → v2}/caixin/database.js +14 -14
- package/lib/v2/caixin/k.js +40 -0
- package/lib/v2/caixin/latest.js +50 -0
- package/lib/v2/caixin/maintainer.js +8 -0
- package/lib/v2/caixin/radar.js +43 -0
- package/lib/v2/caixin/router.js +8 -0
- package/lib/v2/caixin/templates/article.art +38 -0
- package/lib/v2/caixin/utils.js +52 -0
- package/lib/v2/cast/index.js +74 -0
- package/lib/v2/cast/maintainer.js +3 -0
- package/lib/v2/cast/radar.js +13 -0
- package/lib/v2/cast/router.js +3 -0
- package/lib/v2/chaincatcher/home.js +50 -0
- package/lib/v2/chaincatcher/maintainer.js +4 -0
- package/lib/v2/chaincatcher/news.js +40 -0
- package/lib/v2/chaincatcher/radar.js +19 -0
- package/lib/v2/chaincatcher/router.js +4 -0
- package/lib/v2/chaincatcher/templates/home.art +4 -0
- package/lib/v2/clickme/index.js +56 -0
- package/lib/v2/clickme/maintainer.js +3 -0
- package/lib/v2/clickme/radar.js +21 -0
- package/lib/v2/clickme/router.js +3 -0
- package/lib/v2/cnbc/rss.js +1 -1
- package/lib/v2/cnjxol/index.js +3 -0
- package/lib/v2/coindesk/index.js +36 -0
- package/lib/v2/coindesk/maintainer.js +3 -0
- package/lib/v2/coindesk/radar.js +13 -0
- package/lib/v2/coindesk/router.js +3 -0
- package/lib/v2/coolapk/utils.js +3 -2
- package/lib/v2/copymanga/comic.js +110 -0
- package/lib/v2/copymanga/maintainer.js +3 -0
- package/lib/v2/copymanga/radar.js +19 -0
- package/lib/v2/copymanga/router.js +3 -0
- package/lib/v2/copymanga/templates/comic.art +4 -0
- package/lib/v2/crac/index.js +46 -0
- package/lib/v2/crac/maintainer.js +3 -0
- package/lib/v2/crac/radar.js +13 -0
- package/lib/v2/crac/router.js +3 -0
- package/lib/v2/cw/author.js +18 -0
- package/lib/v2/cw/maintainer.js +1 -0
- package/lib/v2/cw/master.js +6 -19
- package/lib/v2/cw/radar.js +6 -0
- package/lib/v2/cw/router.js +1 -0
- package/lib/v2/cw/sub.js +6 -19
- package/lib/v2/cw/today.js +6 -15
- package/lib/v2/cw/utils.js +78 -20
- package/lib/{routes → v2}/dlsite/campaign.js +22 -24
- package/lib/v2/dlsite/maintainer.js +4 -0
- package/lib/{routes → v2}/dlsite/new.js +27 -28
- package/lib/v2/dlsite/radar.js +15 -0
- package/lib/v2/dlsite/router.js +4 -0
- package/lib/v2/dmzj/maintainer.js +3 -0
- package/lib/v2/dmzj/news.js +26 -0
- package/lib/v2/dmzj/radar.js +67 -0
- package/lib/v2/dmzj/router.js +3 -0
- package/lib/v2/douban/other/weekly_best.js +11 -4
- package/lib/v2/douban/templates/weekly_best.art +10 -0
- package/lib/v2/dut/index.js +4 -0
- package/lib/v2/eagle/blog.js +6 -2
- package/lib/v2/economist/espresso.js +55 -25
- package/lib/v2/economist/global-business-review.js +86 -0
- package/lib/v2/economist/maintainer.js +1 -0
- package/lib/v2/economist/radar.js +11 -0
- package/lib/v2/economist/router.js +1 -0
- package/lib/v2/ehentai/ehapi.js +10 -5
- package/lib/v2/ehentai/favorites.js +2 -2
- package/lib/v2/ehentai/search.js +2 -2
- package/lib/v2/ehentai/tag.js +1 -1
- package/lib/v2/eleduck/jobs.js +38 -0
- package/lib/v2/eleduck/maintainer.js +4 -0
- package/lib/v2/eleduck/posts.js +41 -0
- package/lib/v2/eleduck/radar.js +25 -0
- package/lib/v2/eleduck/router.js +4 -0
- package/lib/v2/eprice/rss.js +8 -16
- package/lib/v2/eprice/templates/image.art +4 -1
- package/lib/v2/famitsu/category.js +62 -0
- package/lib/v2/famitsu/maintainer.js +3 -0
- package/lib/v2/famitsu/radar.js +13 -0
- package/lib/v2/famitsu/router.js +3 -0
- package/lib/v2/ff14/ff14_global.js +5 -0
- package/lib/v2/fjksbm/index.js +53 -0
- package/lib/v2/fjksbm/maintainer.js +3 -0
- package/lib/v2/fjksbm/radar.js +13 -0
- package/lib/v2/fjksbm/router.js +3 -0
- package/lib/v2/gamme/category.js +4 -0
- package/lib/v2/gamme/tag.js +4 -0
- package/lib/v2/gelonghui/hot-article.js +33 -0
- package/lib/v2/gelonghui/live.js +31 -0
- package/lib/v2/gelonghui/radar.js +12 -0
- package/lib/v2/gelonghui/router.js +2 -0
- package/lib/v2/gelonghui/templates/live.art +7 -0
- package/lib/v2/gelonghui/utils.js +6 -0
- package/lib/v2/github/maintainer.js +1 -0
- package/lib/v2/github/radar.js +35 -29
- package/lib/v2/github/router.js +1 -0
- package/lib/v2/github/wiki.js +32 -0
- package/lib/v2/google/maintainer.js +1 -0
- package/lib/v2/google/news.js +48 -66
- package/lib/v2/google/router.js +1 -0
- package/lib/v2/google/templates/news.art +5 -0
- package/lib/v2/gov/maintainer.js +1 -0
- package/lib/v2/gov/radar.js +11 -0
- package/lib/v2/gov/router.js +1 -0
- package/lib/v2/gov/wuhan/whyw.js +44 -0
- package/lib/v2/gq/maintainer.js +3 -0
- package/lib/v2/gq/radar.js +13 -0
- package/lib/v2/gq/router.js +3 -0
- package/lib/v2/gq/templates/embed-article.art +1 -0
- package/lib/v2/gq/templates/embed-product.art +4 -0
- package/lib/v2/gq/templates/img.art +6 -0
- package/lib/v2/gq/templates/tw.art +3 -0
- package/lib/v2/gq/templates/videoObject.art +6 -0
- package/lib/v2/gq/templates/youtube.art +3 -0
- package/lib/v2/gq/tw/index.js +165 -0
- package/lib/v2/guandian/index.js +37 -0
- package/lib/v2/guandian/maintainer.js +3 -0
- package/lib/v2/guandian/radar.js +13 -0
- package/lib/v2/guandian/router.js +3 -0
- package/lib/v2/gumroad/index.js +4 -0
- package/lib/v2/hackmd/maintainer.js +3 -0
- package/lib/v2/hackmd/profile.js +24 -0
- package/lib/v2/hackmd/radar.js +13 -0
- package/lib/v2/hackmd/router.js +3 -0
- package/lib/v2/hellogithub/maintainer.js +1 -1
- package/lib/v2/hellogithub/volume.js +13 -12
- package/lib/v2/hljucm/maintainer.js +3 -0
- package/lib/v2/hljucm/radar.js +13 -0
- package/lib/v2/hljucm/router.js +3 -0
- package/lib/v2/hljucm/yjsy.js +56 -0
- package/lib/v2/hotukdeals/hottest.js +25 -0
- package/lib/v2/hotukdeals/maintainer.js +1 -0
- package/lib/v2/hotukdeals/radar.js +6 -0
- package/lib/v2/hotukdeals/router.js +1 -0
- package/lib/v2/huanqiu/index.js +5 -0
- package/lib/v2/huxiu/article.js +14 -11
- package/lib/v2/huxiu/author.js +11 -20
- package/lib/v2/huxiu/briefColumn.js +28 -38
- package/lib/v2/huxiu/collection.js +20 -15
- package/lib/v2/huxiu/moment.js +1 -2
- package/lib/v2/huxiu/search.js +19 -7
- package/lib/v2/huxiu/tag.js +17 -10
- package/lib/v2/huxiu/templates/brief.art +22 -0
- package/lib/v2/huxiu/templates/img.art +3 -0
- package/lib/v2/huxiu/templates/video.art +7 -0
- package/lib/v2/huxiu/utils.js +137 -52
- package/lib/v2/iiilab/index.js +24 -0
- package/lib/v2/iiilab/maintainer.js +3 -0
- package/lib/v2/iiilab/radar.js +13 -0
- package/lib/v2/iiilab/router.js +3 -0
- package/lib/v2/ikea/cn/family_offers.js +70 -0
- package/lib/v2/ikea/cn/low_price.js +22 -0
- package/lib/v2/ikea/cn/new.js +39 -0
- package/lib/v2/ikea/cn/utils.js +42 -0
- package/lib/v2/ikea/gb/new.js +54 -0
- package/lib/v2/ikea/gb/offer.js +69 -0
- package/lib/v2/ikea/maintainer.js +7 -0
- package/lib/v2/ikea/radar.js +42 -0
- package/lib/v2/ikea/router.js +7 -0
- package/lib/v2/ikea/templates/cn/product.art +14 -0
- package/lib/v2/ikea/templates/new.art +7 -0
- package/lib/v2/ikea/templates/offer.art +3 -0
- package/lib/v2/inewsweek/index.js +53 -0
- package/lib/v2/inewsweek/maintainer.js +3 -0
- package/lib/v2/inewsweek/radar.js +13 -0
- package/lib/v2/inewsweek/router.js +3 -0
- package/lib/v2/iqiyi/album.js +62 -0
- package/lib/v2/iqiyi/maintainer.js +4 -0
- package/lib/v2/iqiyi/radar.js +24 -0
- package/lib/v2/iqiyi/router.js +4 -0
- package/lib/v2/iqiyi/templates/album.art +1 -0
- package/lib/{routes → v2}/iqiyi/video.js +0 -0
- package/lib/v2/itch/devlog.js +4 -0
- package/lib/v2/iwara/index.js +1 -0
- package/lib/v2/javbus/index.js +12 -2
- package/lib/v2/javdb/utils.js +6 -0
- package/lib/v2/jike/maintainer.js +1 -1
- package/lib/v2/jike/router.js +1 -1
- package/lib/v2/jike/topic.js +1 -1
- package/lib/v2/jike/user.js +22 -12
- package/lib/v2/jike/utils.js +4 -2
- package/lib/v2/ke/maintainer.js +3 -0
- package/lib/v2/ke/radar.js +13 -0
- package/lib/v2/ke/results.js +36 -0
- package/lib/v2/ke/router.js +3 -0
- package/lib/v2/kimlaw/maintainer.js +3 -0
- package/lib/v2/kimlaw/radar.js +13 -0
- package/lib/v2/kimlaw/router.js +3 -0
- package/lib/v2/kimlaw/thesis.js +44 -0
- package/lib/v2/layoffs/index.js +104 -0
- package/lib/v2/layoffs/maintainer.js +3 -0
- package/lib/v2/layoffs/radar.js +13 -0
- package/lib/v2/layoffs/router.js +3 -0
- package/lib/v2/learnblockchain/maintainer.js +3 -0
- package/lib/v2/learnblockchain/posts.js +43 -0
- package/lib/v2/learnblockchain/radar.js +19 -0
- package/lib/v2/learnblockchain/router.js +3 -0
- package/lib/v2/linkedin/cn/index.js +13 -0
- package/lib/v2/linkedin/cn/renderer.js +179 -0
- package/lib/v2/linkedin/cn/utils.js +122 -0
- package/lib/v2/linkedin/jobs.js +44 -0
- package/lib/v2/linkedin/maintainer.js +4 -0
- package/lib/v2/linkedin/models.js +15 -0
- package/lib/v2/linkedin/radar.js +36 -0
- package/lib/v2/linkedin/router.js +4 -0
- package/lib/v2/linkedin/templates/cn/posting.art +25 -0
- package/lib/v2/linkedin/utils.js +121 -0
- package/lib/v2/lofter/user.js +6 -2
- package/lib/v2/mclaren/index.js +95 -0
- package/lib/v2/mclaren/maintainer.js +3 -0
- package/lib/v2/mclaren/radar.js +26 -0
- package/lib/v2/mclaren/router.js +3 -0
- package/lib/v2/mclaren/templates/desc.art +6 -0
- package/lib/v2/minecraft/maintainer.js +3 -0
- package/lib/v2/minecraft/radar.js +13 -0
- package/lib/v2/minecraft/router.js +3 -0
- package/lib/{routes → v2}/minecraft/version.js +1 -1
- package/lib/v2/mingpao/index.js +28 -33
- package/lib/v2/mingpao/templates/description.art +1 -1
- package/lib/v2/mingpao/templates/fancybox.art +6 -2
- package/lib/v2/mirror/index.js +4 -1
- package/lib/v2/mixcloud/index.js +130 -0
- package/lib/v2/mixcloud/maintainer.js +3 -0
- package/lib/v2/mixcloud/queries.js +1520 -0
- package/lib/v2/mixcloud/radar.js +37 -0
- package/lib/v2/mixcloud/router.js +3 -0
- package/lib/v2/myfigurecollection/activity.js +5 -0
- package/lib/v2/myfigurecollection/index.js +4 -0
- package/lib/v2/mysql/release.js +9 -2
- package/lib/v2/nikkei-cn/index.js +4 -0
- package/lib/v2/people/index.js +4 -0
- package/lib/v2/pixiv/novels.js +32 -23
- package/lib/v2/pku/ss/admission.js +4 -42
- package/lib/v2/pku/ss/common.js +37 -0
- package/lib/v2/pku/ss/notice.js +4 -42
- package/lib/v2/pku/ss/pg_admin.js +4 -42
- package/lib/v2/qoo-app/apps/card.js +38 -0
- package/lib/v2/qoo-app/apps/comment.js +43 -0
- package/lib/v2/qoo-app/apps/note.js +47 -0
- package/lib/v2/qoo-app/apps/post.js +51 -0
- package/lib/v2/qoo-app/maintainer.js +11 -0
- package/lib/v2/qoo-app/news.js +41 -0
- package/lib/v2/qoo-app/notes/note.js +43 -0
- package/lib/v2/qoo-app/notes/topic.js +20 -0
- package/lib/v2/qoo-app/notes/user.js +20 -0
- package/lib/v2/qoo-app/radar.js +73 -0
- package/lib/v2/qoo-app/router.js +11 -0
- package/lib/v2/qoo-app/templates/comment.art +3 -0
- package/lib/v2/qoo-app/templates/note.art +5 -0
- package/lib/v2/qoo-app/user/appComment.js +41 -0
- package/lib/v2/qoo-app/utils.js +57 -0
- package/lib/v2/ruancan/category.js +8 -0
- package/lib/v2/ruancan/index.js +3 -55
- package/lib/v2/ruancan/maintainer.js +3 -3
- package/lib/v2/ruancan/radar.js +12 -6
- package/lib/v2/ruancan/router.js +4 -1
- package/lib/v2/ruancan/search.js +8 -0
- package/lib/v2/ruancan/user.js +8 -0
- package/lib/v2/ruancan/utils.js +66 -0
- package/lib/v2/scitation/journal.js +4 -0
- package/lib/v2/scitation/section.js +4 -0
- package/lib/v2/shiep/index.js +91 -0
- package/lib/v2/shiep/maintainer.js +3 -0
- package/lib/v2/shiep/radar.js +181 -0
- package/lib/v2/shiep/router.js +3 -0
- package/lib/v2/shiep/templates/description.art +1 -0
- package/lib/v2/shoppingdesign/maintainer.js +3 -0
- package/lib/v2/shoppingdesign/posts.js +43 -0
- package/lib/v2/shoppingdesign/radar.js +13 -0
- package/lib/v2/shoppingdesign/router.js +3 -0
- package/lib/v2/skysports/maintainer.js +3 -0
- package/lib/{routes → v2}/skysports/news.js +10 -8
- package/lib/v2/skysports/radar.js +13 -0
- package/lib/v2/skysports/router.js +3 -0
- package/lib/v2/smzdm/haowen_fenlei.js +12 -6
- package/lib/v2/solidot/main.js +5 -0
- package/lib/v2/telegram/channel.js +24 -4
- package/lib/v2/test/index.js +46 -0
- package/lib/v2/thepaper/channel.js +11 -5
- package/lib/v2/thepaper/list.js +11 -5
- package/lib/v2/thepaper/utils.js +2 -3
- package/lib/v2/twitter/utils.js +28 -0
- package/lib/v2/typora/changelog-dev.js +31 -0
- package/lib/v2/typora/changelog.js +40 -0
- package/lib/v2/typora/maintainer.js +4 -0
- package/lib/v2/typora/radar.js +21 -0
- package/lib/v2/typora/router.js +4 -0
- package/lib/v2/uptimerobot/maintainer.js +3 -0
- package/lib/v2/uptimerobot/radar.js +13 -0
- package/lib/v2/uptimerobot/router.js +3 -0
- package/lib/v2/uptimerobot/rss.js +126 -0
- package/lib/v2/uptimerobot/templates/rss.art +20 -0
- package/lib/v2/vocus/maintainer.js +4 -0
- package/lib/v2/vocus/publication.js +42 -0
- package/lib/v2/vocus/radar.js +19 -0
- package/lib/v2/vocus/router.js +4 -0
- package/lib/v2/vocus/user.js +43 -0
- package/lib/v2/vocus/utils.js +51 -0
- package/lib/v2/wechat/maintainer.js +0 -1
- package/lib/v2/wechat/radar.js +0 -11
- package/lib/v2/wechat/router.js +0 -1
- package/lib/v2/wnacg/index.js +110 -0
- package/lib/v2/wnacg/maintainer.js +5 -0
- package/lib/v2/wnacg/radar.js +25 -0
- package/lib/v2/wnacg/router.js +5 -0
- package/lib/v2/wnacg/templates/manga.art +9 -0
- package/lib/v2/woshipm/bookmarks.js +34 -0
- package/lib/v2/woshipm/latest.js +27 -0
- package/lib/v2/woshipm/maintainer.js +7 -0
- package/lib/v2/woshipm/popular.js +33 -0
- package/lib/v2/woshipm/radar.js +39 -0
- package/lib/v2/woshipm/router.js +7 -0
- package/lib/{routes → v2}/woshipm/user_article.js +9 -15
- package/lib/v2/woshipm/utils.js +21 -0
- package/lib/v2/woshipm/wen.js +36 -0
- package/lib/v2/x6d/index.js +59 -0
- package/lib/v2/x6d/maintainer.js +3 -0
- package/lib/v2/x6d/radar.js +13 -0
- package/lib/v2/x6d/router.js +3 -0
- package/lib/v2/xaufe/jiaowu.js +72 -0
- package/lib/v2/xaufe/maintainer.js +3 -0
- package/lib/v2/xaufe/radar.js +11 -0
- package/lib/v2/xaufe/router.js +3 -0
- package/lib/v2/xiaomiyoupin/crowdfunding.js +43 -0
- package/lib/v2/xiaomiyoupin/latest.js +15 -0
- package/lib/v2/xiaomiyoupin/maintainer.js +4 -0
- package/lib/v2/xiaomiyoupin/radar.js +19 -0
- package/lib/v2/xiaomiyoupin/router.js +4 -0
- package/lib/v2/xiaomiyoupin/templates/goods.art +27 -0
- package/lib/v2/xiaomiyoupin/utils.js +21 -0
- package/lib/v2/xunhupay/index.js +24 -0
- package/lib/v2/xunhupay/maintainer.js +3 -0
- package/lib/v2/xunhupay/radar.js +13 -0
- package/lib/v2/xunhupay/router.js +3 -0
- package/lib/v2/yahoo/maintainer.js +3 -0
- package/lib/{routes/yahoo-news → v2/yahoo/news}/index.js +10 -8
- package/lib/v2/yahoo/radar.js +13 -0
- package/lib/v2/yahoo/router.js +3 -0
- package/lib/v2/youtube/user.js +15 -3
- package/lib/v2/yxrb/home.js +61 -0
- package/lib/v2/yxrb/maintainer.js +3 -0
- package/lib/v2/yxrb/radar.js +13 -0
- package/lib/v2/yxrb/router.js +3 -0
- package/lib/v2/zaozao/article.js +36 -0
- package/lib/v2/zaozao/maintainer.js +3 -0
- package/lib/v2/zaozao/radar.js +13 -0
- package/lib/v2/zaozao/router.js +3 -0
- package/lib/v2/zcmu/jwc/index.js +41 -0
- package/lib/v2/zcmu/maintainer.js +4 -0
- package/lib/v2/zcmu/radar.js +87 -0
- package/lib/v2/zcmu/router.js +4 -0
- package/lib/v2/zcmu/yxy/index.js +42 -0
- package/lib/v2/zcool/user.js +4 -0
- package/lib/v2/zhiy/letter.js +34 -0
- package/lib/v2/zhiy/maintainer.js +4 -0
- package/lib/v2/zhiy/post.js +69 -0
- package/lib/v2/zhiy/radar.js +19 -0
- package/lib/v2/zhiy/router.js +4 -0
- package/lib/v2/zhiy/templates/post.art +12 -0
- package/lib/v2/zhiy/utils.js +13 -0
- package/lib/v2/zhubai/index.js +4 -0
- package/package.json +20 -20
- package/lib/routes/baidu/topwords.js +0 -38
- package/lib/routes/bjp/apod.js +0 -48
- package/lib/routes/caixin/article.js +0 -46
- package/lib/routes/caixin/blog.js +0 -58
- package/lib/routes/caixin/category.js +0 -44
- package/lib/routes/caixin/latest.js +0 -75
- package/lib/routes/caixin/yxnews.js +0 -30
- package/lib/routes/clickme/index.js +0 -76
- package/lib/routes/copymanga/comic.js +0 -74
- package/lib/routes/eleduck/jobs.js +0 -38
- package/lib/routes/gq/tw/index.js +0 -66
- package/lib/routes/ikea/uk/new.js +0 -20
- package/lib/routes/ikea/uk/offer.js +0 -64
- package/lib/routes/iqiyi/dongman.js +0 -42
- package/lib/routes/mi/youpin/crowdfunding.js +0 -39
- package/lib/routes/mi/youpin/new.js +0 -26
- package/lib/routes/ssmh/category.js +0 -50
- package/lib/routes/ssmh/index.js +0 -32
- package/lib/routes/typora/changelog-dev.js +0 -35
- package/lib/routes/typora/changelog.js +0 -60
- package/lib/routes/universities/shiep/index.js +0 -95
- package/lib/routes/vocus/publication.js +0 -19
- package/lib/routes/vocus/utils.js +0 -29
- package/lib/routes/woshipm/bookmarks.js +0 -45
- package/lib/routes/woshipm/latest.js +0 -45
- package/lib/routes/woshipm/popular.js +0 -38
- package/lib/routes/woshipm/wen.js +0 -39
- package/lib/routes/x6d/index.js +0 -64
- package/lib/v2/eprice/templates/description.art +0 -1
- package/lib/v2/wechat/wemp.js +0 -58
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
ctx.params.caty = ctx.params.caty || '';
|
|
6
|
-
ctx.params.subcaty = ctx.params.subcaty || '';
|
|
7
|
-
|
|
8
|
-
const rootUrl = 'https://www.gq.com.tw';
|
|
9
|
-
const currentUrl = `${rootUrl}${ctx.params.caty === '' ? '' : '/' + ctx.params.caty}${ctx.params.subcaty === '' ? '' : '/' + ctx.params.subcaty}`;
|
|
10
|
-
const response = await got({
|
|
11
|
-
method: 'get',
|
|
12
|
-
url: currentUrl,
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
const $ = cheerio.load(response.data);
|
|
16
|
-
|
|
17
|
-
$('a[data-test-id="NavElement"]').remove();
|
|
18
|
-
$('a[data-test-id="Link"]').remove();
|
|
19
|
-
$('a[data-test-id="FooterLink"]').remove();
|
|
20
|
-
|
|
21
|
-
const list = $('a[data-test-id]')
|
|
22
|
-
.slice(0, 10)
|
|
23
|
-
.map((_, item) => {
|
|
24
|
-
item = $(item);
|
|
25
|
-
return {
|
|
26
|
-
link: `${rootUrl}${item.attr('href')}`,
|
|
27
|
-
};
|
|
28
|
-
})
|
|
29
|
-
.get();
|
|
30
|
-
|
|
31
|
-
const items = await Promise.all(
|
|
32
|
-
list.map((item) =>
|
|
33
|
-
ctx.cache.tryGet(item.link, async () => {
|
|
34
|
-
const detailResponse = await got({
|
|
35
|
-
method: 'get',
|
|
36
|
-
url: item.link,
|
|
37
|
-
});
|
|
38
|
-
const content = cheerio.load(detailResponse.data);
|
|
39
|
-
|
|
40
|
-
item.title = content('h1').text();
|
|
41
|
-
|
|
42
|
-
const article = content('section[data-test-id="ArticleBodyContent"]').html();
|
|
43
|
-
const gallery = content('section[data-test-id="GalleryImage"]').html();
|
|
44
|
-
|
|
45
|
-
if (ctx.params.caty === 'video') {
|
|
46
|
-
item.description = content('div[data-test-id="EmbedIframe"]').html() + content('p[data-test-id="DekText"]').parent().html();
|
|
47
|
-
item.pubDate = new Date(detailResponse.data.match(/pubDate":"(.*?)","channel/)[1]).toUTCString();
|
|
48
|
-
} else if (gallery !== null) {
|
|
49
|
-
item.description = gallery;
|
|
50
|
-
item.pubDate = new Date(detailResponse.data.match(/pubDate":"(.*?)","items/)[1]).toUTCString();
|
|
51
|
-
} else {
|
|
52
|
-
item.description = article;
|
|
53
|
-
item.pubDate = new Date(detailResponse.data.match(/pubDate":"(.*?)","publishedRevisions/)[1]).toUTCString();
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
return item;
|
|
57
|
-
})
|
|
58
|
-
)
|
|
59
|
-
);
|
|
60
|
-
|
|
61
|
-
ctx.state.data = {
|
|
62
|
-
title: `${$('title').eq(0).text()} - GQ Taiwan`,
|
|
63
|
-
link: currentUrl,
|
|
64
|
-
item: items,
|
|
65
|
-
};
|
|
66
|
-
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
|
|
3
|
-
module.exports = async (ctx) => {
|
|
4
|
-
const link = 'https://www.ikea.com/gb/en/news/product-news-gallery/';
|
|
5
|
-
|
|
6
|
-
const count = (await got.get('https://sik.search.blue.cdtapps.com/gb/en/product-list-page?category=products&f-toggles2=new_product')).data.productListPage.productCount;
|
|
7
|
-
|
|
8
|
-
const products = (await got.get(`http://sik.search.blue.cdtapps.com/gb/en/product-list-page/more-products?category=products&start=1&end=${count}`)).data.moreProducts.productWindow;
|
|
9
|
-
|
|
10
|
-
ctx.state.data = {
|
|
11
|
-
title: 'IKEA UK - New Products',
|
|
12
|
-
link,
|
|
13
|
-
description: 'New products released by IKEA UK.',
|
|
14
|
-
item: products.map((p) => ({
|
|
15
|
-
title: `${p.name} ${p.typeName} ${p.itemMeasureReferenceText}`,
|
|
16
|
-
description: `<img src="${p.mainImageUrl}">`,
|
|
17
|
-
link: p.pipUrl,
|
|
18
|
-
})),
|
|
19
|
-
};
|
|
20
|
-
};
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const link = 'https://www.ikea.com/gb/en/ikea-family/discounts/';
|
|
6
|
-
|
|
7
|
-
const items = [];
|
|
8
|
-
|
|
9
|
-
const loadProductsOnPage = (data) => {
|
|
10
|
-
const $ = cheerio.load(data);
|
|
11
|
-
const products = $('.range-revamp-product-compact').get();
|
|
12
|
-
|
|
13
|
-
if (products.length > 0) {
|
|
14
|
-
for (const p of products) {
|
|
15
|
-
const price = $(p).find('.range-revamp-compact-price-package__price-wrapper').text();
|
|
16
|
-
|
|
17
|
-
if (!price) {
|
|
18
|
-
continue;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
let title = $(p).find('.range-revamp-header-section__title--small').text() + ' ';
|
|
22
|
-
|
|
23
|
-
title += $(p).find('.range-revamp-header-section__description-text').text().trim() + ' ';
|
|
24
|
-
|
|
25
|
-
const previous = $(p).find('.range-revamp-compact-price-package__previous-price-text').next('span').text();
|
|
26
|
-
|
|
27
|
-
title += `[${previous} ▶️ ${price}]`;
|
|
28
|
-
|
|
29
|
-
const link = $(p).find('.range-revamp-product-compact__bottom-wrapper > a').attr('href');
|
|
30
|
-
|
|
31
|
-
items.push({
|
|
32
|
-
title,
|
|
33
|
-
description: `<img src='${$($(p).find('.range-revamp-aspect-ratio-image__image')[1]).attr('data-src')}'>`,
|
|
34
|
-
link,
|
|
35
|
-
});
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
};
|
|
39
|
-
|
|
40
|
-
const response = await got.get(link);
|
|
41
|
-
|
|
42
|
-
loadProductsOnPage(response.data);
|
|
43
|
-
|
|
44
|
-
const $ = cheerio.load(response.data);
|
|
45
|
-
const list = $('.text.component a')
|
|
46
|
-
.get()
|
|
47
|
-
.map((e) => $(e).attr('href'));
|
|
48
|
-
|
|
49
|
-
if (list.length > 0) {
|
|
50
|
-
await Promise.all(
|
|
51
|
-
list.map(async (url) => {
|
|
52
|
-
const response = await got.get(url);
|
|
53
|
-
loadProductsOnPage(response.data);
|
|
54
|
-
})
|
|
55
|
-
);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
ctx.state.data = {
|
|
59
|
-
title: 'IKEA UK - Offers',
|
|
60
|
-
link,
|
|
61
|
-
description: 'Offers by IKEA UK.',
|
|
62
|
-
item: items,
|
|
63
|
-
};
|
|
64
|
-
};
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const id = ctx.params.id;
|
|
6
|
-
|
|
7
|
-
const response = await got({
|
|
8
|
-
method: 'get',
|
|
9
|
-
url: `http://www.iqiyi.com/${id}.html`,
|
|
10
|
-
headers: {
|
|
11
|
-
Host: 'www.iqiyi.com',
|
|
12
|
-
Referer: `http://www.iqiyi.com/${id}.html`,
|
|
13
|
-
},
|
|
14
|
-
});
|
|
15
|
-
|
|
16
|
-
const data = response.data;
|
|
17
|
-
const $ = cheerio.load(data);
|
|
18
|
-
const description = $('.episodeIntro-brief').text();
|
|
19
|
-
const list = $('li[data-albumlist-elem="playItem"]');
|
|
20
|
-
|
|
21
|
-
ctx.state.data = {
|
|
22
|
-
title: $('title').text().split('-')[0],
|
|
23
|
-
link: `http://www.iqiyi.com/${id}.html`,
|
|
24
|
-
description,
|
|
25
|
-
item:
|
|
26
|
-
list &&
|
|
27
|
-
list
|
|
28
|
-
.map((index, item) => {
|
|
29
|
-
const episode = $(item).find('p.site-piclist_info_title a').text().trim();
|
|
30
|
-
const describe = $(item).find('p.site-piclist_info_describe a').text();
|
|
31
|
-
const title = `${episode}-${describe}`;
|
|
32
|
-
|
|
33
|
-
return {
|
|
34
|
-
title,
|
|
35
|
-
description: `<img src="${$(item).find('.site-piclist_pic .site-piclist_pic_link img').attr('src')}">`,
|
|
36
|
-
link: $(item).find('.site-piclist_pic .site-piclist_pic_link').attr('href'),
|
|
37
|
-
};
|
|
38
|
-
})
|
|
39
|
-
.get()
|
|
40
|
-
.reverse(),
|
|
41
|
-
};
|
|
42
|
-
};
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
|
|
3
|
-
module.exports = async (ctx) => {
|
|
4
|
-
const response = await got({
|
|
5
|
-
method: 'get',
|
|
6
|
-
url: 'https://home.mi.com/lasagne/page/5',
|
|
7
|
-
});
|
|
8
|
-
|
|
9
|
-
const data = response.data.floors.filter((floor) => floor.floor_id === 99 || floor.floor_id === 100);
|
|
10
|
-
const item = data.reduce((acc, item) => {
|
|
11
|
-
if (!item.data) {
|
|
12
|
-
return acc;
|
|
13
|
-
}
|
|
14
|
-
let goodsList = [];
|
|
15
|
-
|
|
16
|
-
if (item.data.result) {
|
|
17
|
-
goodsList = item.data.result.goods_list;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
goodsList.forEach((goods) => {
|
|
21
|
-
const img = goods.pic_url;
|
|
22
|
-
acc.push({
|
|
23
|
-
title: goods.name,
|
|
24
|
-
description: `<img src="${img}"><br>${goods.summary}<br>价格:${goods.market_price / 100}元`,
|
|
25
|
-
link: goods.jump_url,
|
|
26
|
-
pubDate: new Date(goods.first_release_time * 1000).toUTCString(),
|
|
27
|
-
});
|
|
28
|
-
});
|
|
29
|
-
|
|
30
|
-
return acc;
|
|
31
|
-
}, []);
|
|
32
|
-
|
|
33
|
-
ctx.state.data = {
|
|
34
|
-
title: '小米有品众筹',
|
|
35
|
-
link: 'https://m.xiaomiyoupin.com/w/crowdfunding?pageid=5',
|
|
36
|
-
description: '小米有品众筹',
|
|
37
|
-
item,
|
|
38
|
-
};
|
|
39
|
-
};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
|
|
3
|
-
module.exports = async (ctx) => {
|
|
4
|
-
const response = await got({
|
|
5
|
-
method: 'post',
|
|
6
|
-
url: 'https://m.xiaomiyoupin.com/homepage/main/v1005',
|
|
7
|
-
});
|
|
8
|
-
|
|
9
|
-
const items = response.data.data.homepage.floors
|
|
10
|
-
.filter((floor) => floor.module_key === 'product_hot')[0]
|
|
11
|
-
.data.items.map((item) => {
|
|
12
|
-
const i = item.item;
|
|
13
|
-
return {
|
|
14
|
-
title: i.name,
|
|
15
|
-
description: `<img src="${i.pic_url}"><br>${i.summary}<br>价格:${i.market_price / 100}元`,
|
|
16
|
-
link: i.jump_url,
|
|
17
|
-
};
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
ctx.state.data = {
|
|
21
|
-
title: '小米有品每日上新',
|
|
22
|
-
link: 'https://m.xiaomiyoupin.com/w/newproduct?pageid=1605',
|
|
23
|
-
description: '小米有品每日上新',
|
|
24
|
-
item: items,
|
|
25
|
-
};
|
|
26
|
-
};
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
const categories = {
|
|
5
|
-
1: '同人誌 漢化',
|
|
6
|
-
2: '同人誌 CG畫集',
|
|
7
|
-
3: '同人誌 Cosplay',
|
|
8
|
-
5: '同人誌',
|
|
9
|
-
6: '單行本',
|
|
10
|
-
7: '雜誌&短篇',
|
|
11
|
-
9: '單行本 漢化',
|
|
12
|
-
10: '雜誌&短篇 漢化',
|
|
13
|
-
12: '同人誌 日語',
|
|
14
|
-
13: '單行本 日語',
|
|
15
|
-
14: '雜誌&短篇 日語',
|
|
16
|
-
};
|
|
17
|
-
|
|
18
|
-
module.exports = async (ctx) => {
|
|
19
|
-
const cid = ctx.params.cid;
|
|
20
|
-
if (!cid || !Object.keys(categories).includes(cid)) {
|
|
21
|
-
ctx.state.data = {
|
|
22
|
-
title: '此分类不存在',
|
|
23
|
-
};
|
|
24
|
-
return;
|
|
25
|
-
}
|
|
26
|
-
const url = `https://www.wnacg.com/albums-index-cate-${cid}.html`;
|
|
27
|
-
const response = await got.get(url);
|
|
28
|
-
|
|
29
|
-
const data = response.data;
|
|
30
|
-
|
|
31
|
-
const $ = cheerio.load(data);
|
|
32
|
-
const list = $('.pic_box');
|
|
33
|
-
|
|
34
|
-
ctx.state.data = {
|
|
35
|
-
title: '紳士漫畫 - ' + categories[cid],
|
|
36
|
-
link: url,
|
|
37
|
-
item: list
|
|
38
|
-
.map((index, item) => {
|
|
39
|
-
item = $(item);
|
|
40
|
-
const thumbnail_url = 'https:' + (item.find('a > img').attr('src') ? item.find('a > img').attr('src') : item.find('a > img').attr('data-original'));
|
|
41
|
-
const link_url = 'https://wnacg.org' + item.find('a').attr('href');
|
|
42
|
-
return {
|
|
43
|
-
title: item.find('a').attr('title'),
|
|
44
|
-
description: `<img src=${thumbnail_url} referrerpolicy="no-referrer">`,
|
|
45
|
-
link: link_url,
|
|
46
|
-
};
|
|
47
|
-
})
|
|
48
|
-
.get(),
|
|
49
|
-
};
|
|
50
|
-
};
|
package/lib/routes/ssmh/index.js
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const response = await got({
|
|
6
|
-
method: 'get',
|
|
7
|
-
url: 'https://wnacg.org/albums.html',
|
|
8
|
-
});
|
|
9
|
-
|
|
10
|
-
const data = response.data;
|
|
11
|
-
|
|
12
|
-
const $ = cheerio.load(data);
|
|
13
|
-
const list = $('.pic_box');
|
|
14
|
-
let thumbnail_url;
|
|
15
|
-
let link_url;
|
|
16
|
-
ctx.state.data = {
|
|
17
|
-
title: '紳士漫畫',
|
|
18
|
-
link: 'https://wnacg.org/albums.html',
|
|
19
|
-
item: list
|
|
20
|
-
.map((index, item) => {
|
|
21
|
-
item = $(item);
|
|
22
|
-
thumbnail_url = `https:${item.find('a > img').attr('src') ?? item.find('a > img').attr('data-original')}`;
|
|
23
|
-
link_url = `https://wnacg.org${item.find('a').attr('href')}`;
|
|
24
|
-
return {
|
|
25
|
-
title: item.find('a').attr('title'),
|
|
26
|
-
description: `<img src=${thumbnail_url} referrerpolicy="no-referrer">`,
|
|
27
|
-
link: link_url,
|
|
28
|
-
};
|
|
29
|
-
})
|
|
30
|
-
.get(),
|
|
31
|
-
};
|
|
32
|
-
};
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
ctx.params.os = ctx.params.os || 'macos';
|
|
6
|
-
|
|
7
|
-
const currentUrl = `https://typora.io${ctx.params.os.toLowerCase() === 'macos' ? '' : '/windows'}/dev_release.html`;
|
|
8
|
-
const response = await got({
|
|
9
|
-
method: 'get',
|
|
10
|
-
url: currentUrl,
|
|
11
|
-
});
|
|
12
|
-
|
|
13
|
-
const $ = cheerio.load(response.data.replace(/<h4>/g, '</div><div><h4>'));
|
|
14
|
-
|
|
15
|
-
const items = $('div')
|
|
16
|
-
.slice(0, 10)
|
|
17
|
-
.map((_, item) => {
|
|
18
|
-
item = $(item);
|
|
19
|
-
const h4 = item.find('h4');
|
|
20
|
-
h4.remove();
|
|
21
|
-
return {
|
|
22
|
-
title: h4.text(),
|
|
23
|
-
link: currentUrl,
|
|
24
|
-
description: item.html(),
|
|
25
|
-
};
|
|
26
|
-
})
|
|
27
|
-
.get();
|
|
28
|
-
|
|
29
|
-
ctx.state.data = {
|
|
30
|
-
title: `Typora Changelog - ${ctx.params.os.toLowerCase() === 'macos' ? 'macOS' : 'Windows/Linux'}`,
|
|
31
|
-
link: currentUrl,
|
|
32
|
-
description: 'Typora Changelog',
|
|
33
|
-
item: items,
|
|
34
|
-
};
|
|
35
|
-
};
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const host = 'https://support.typora.io/';
|
|
6
|
-
|
|
7
|
-
const response = await got({
|
|
8
|
-
method: 'get',
|
|
9
|
-
url: host,
|
|
10
|
-
headers: {
|
|
11
|
-
Referer: host,
|
|
12
|
-
},
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
const $ = cheerio.load(response.data);
|
|
16
|
-
|
|
17
|
-
const loadContent = async (link) => {
|
|
18
|
-
const response = await got({
|
|
19
|
-
method: 'get',
|
|
20
|
-
url: link,
|
|
21
|
-
headers: {
|
|
22
|
-
Referer: host,
|
|
23
|
-
},
|
|
24
|
-
});
|
|
25
|
-
|
|
26
|
-
const $ = cheerio.load(response.data);
|
|
27
|
-
|
|
28
|
-
const title = $('h1').text();
|
|
29
|
-
const pubDate = new Date($('.post-meta time').text());
|
|
30
|
-
// const author = $('.post-meta span').text();
|
|
31
|
-
const html = $('#pagecontainer').html();
|
|
32
|
-
|
|
33
|
-
return {
|
|
34
|
-
title,
|
|
35
|
-
link,
|
|
36
|
-
guid: link,
|
|
37
|
-
pubDate,
|
|
38
|
-
description: html,
|
|
39
|
-
};
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
const items = await Promise.all(
|
|
43
|
-
$('#list-contents > ul:nth-child(2) > li')
|
|
44
|
-
.get()
|
|
45
|
-
.map(async (item) => {
|
|
46
|
-
const node = $('a', item);
|
|
47
|
-
const link = node.attr('href');
|
|
48
|
-
const result = await ctx.cache.tryGet(link, () => loadContent(link));
|
|
49
|
-
|
|
50
|
-
return Promise.resolve(result);
|
|
51
|
-
})
|
|
52
|
-
);
|
|
53
|
-
|
|
54
|
-
ctx.state.data = {
|
|
55
|
-
title: 'Typora Changelog',
|
|
56
|
-
link: host,
|
|
57
|
-
description: 'Typora Changelog',
|
|
58
|
-
item: items,
|
|
59
|
-
};
|
|
60
|
-
};
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const type = ctx.params.type;
|
|
6
|
-
|
|
7
|
-
const config = {
|
|
8
|
-
news: {
|
|
9
|
-
title: '新闻网',
|
|
10
|
-
url: 'notice',
|
|
11
|
-
},
|
|
12
|
-
energy: {
|
|
13
|
-
title: '能机学院',
|
|
14
|
-
url: '894',
|
|
15
|
-
},
|
|
16
|
-
hhxy: {
|
|
17
|
-
title: '环化学院',
|
|
18
|
-
url: '1231',
|
|
19
|
-
},
|
|
20
|
-
dqxy: {
|
|
21
|
-
title: '电气学院',
|
|
22
|
-
url: '2462',
|
|
23
|
-
},
|
|
24
|
-
zdhxy: {
|
|
25
|
-
title: '自动化学院',
|
|
26
|
-
url: '2002',
|
|
27
|
-
},
|
|
28
|
-
jsjxy: {
|
|
29
|
-
title: '计算机学院',
|
|
30
|
-
url: '973',
|
|
31
|
-
},
|
|
32
|
-
dxxy: {
|
|
33
|
-
title: '电信学院',
|
|
34
|
-
url: '3404',
|
|
35
|
-
},
|
|
36
|
-
jgxy: {
|
|
37
|
-
title: '经管学院',
|
|
38
|
-
url: '3633',
|
|
39
|
-
},
|
|
40
|
-
slxy: {
|
|
41
|
-
title: '数理学院',
|
|
42
|
-
url: '2063',
|
|
43
|
-
},
|
|
44
|
-
wgyxy: {
|
|
45
|
-
title: '外国语学院',
|
|
46
|
-
url: 'tzgg',
|
|
47
|
-
},
|
|
48
|
-
gjjlxy: {
|
|
49
|
-
title: '国交学院',
|
|
50
|
-
url: 'tzgg',
|
|
51
|
-
},
|
|
52
|
-
jjxy: {
|
|
53
|
-
title: '继续教育学院',
|
|
54
|
-
url: '2582',
|
|
55
|
-
},
|
|
56
|
-
skb: {
|
|
57
|
-
title: '马院',
|
|
58
|
-
url: '1736',
|
|
59
|
-
},
|
|
60
|
-
tyb: {
|
|
61
|
-
title: '体育部',
|
|
62
|
-
url: '2891',
|
|
63
|
-
},
|
|
64
|
-
yjzx: {
|
|
65
|
-
title: '艺教中心',
|
|
66
|
-
url: '3089',
|
|
67
|
-
},
|
|
68
|
-
};
|
|
69
|
-
|
|
70
|
-
const link = config[type].url;
|
|
71
|
-
|
|
72
|
-
const { data } = await got({
|
|
73
|
-
method: 'get',
|
|
74
|
-
url: `https://${type}.shiep.edu.cn/${link}/list.htm`,
|
|
75
|
-
});
|
|
76
|
-
|
|
77
|
-
const $ = cheerio.load(data);
|
|
78
|
-
const list = $('div[class="fields pr_fields"]');
|
|
79
|
-
|
|
80
|
-
ctx.state.data = {
|
|
81
|
-
title: '上海电力大学-' + config[type].title,
|
|
82
|
-
link: `https://${type}.shiep.edu.cn/${link}/list.htm`,
|
|
83
|
-
item:
|
|
84
|
-
list &&
|
|
85
|
-
list
|
|
86
|
-
.map((index, item) => {
|
|
87
|
-
item = $(item);
|
|
88
|
-
return {
|
|
89
|
-
title: item.find('a').text(),
|
|
90
|
-
link: item.find('a').attr('href'),
|
|
91
|
-
};
|
|
92
|
-
})
|
|
93
|
-
.get(),
|
|
94
|
-
};
|
|
95
|
-
};
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const { ProcessFeed } = require('./utils');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const { id } = ctx.params;
|
|
6
|
-
const link = `https://vocus.cc/${id}/home`;
|
|
7
|
-
const configs = { headers: { Referer: link } };
|
|
8
|
-
|
|
9
|
-
const { _id, title, abstract } = (await got.get(`https://api.sosreader.com/api/publication/${id}`, configs)).data;
|
|
10
|
-
const { articles } = (await got.get(`https://api.sosreader.com/api/articles?publicationId=${_id}&status=2&num=10&page=1`, configs)).data;
|
|
11
|
-
const items = await ProcessFeed(articles, `https://vocus.cc/${id}`, ctx.cache);
|
|
12
|
-
|
|
13
|
-
ctx.state.data = {
|
|
14
|
-
title: `${title} - 方格子`,
|
|
15
|
-
link,
|
|
16
|
-
description: abstract,
|
|
17
|
-
item: items,
|
|
18
|
-
};
|
|
19
|
-
};
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
|
|
3
|
-
const load = async (link, configs) => ({
|
|
4
|
-
description: (await got.get(link, configs)).data.article.content,
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
const ProcessFeed = (list, host, caches) => {
|
|
8
|
-
const configs = { headers: { Referer: host } };
|
|
9
|
-
|
|
10
|
-
return Promise.all(
|
|
11
|
-
list.map(async (item) => {
|
|
12
|
-
const itemUrl = `https://api.sosreader.com/api/article/${item._id}`;
|
|
13
|
-
|
|
14
|
-
const single = {
|
|
15
|
-
title: item.title,
|
|
16
|
-
author: item.user.fullname,
|
|
17
|
-
pubDate: new Date(item.updatedAt).toUTCString(),
|
|
18
|
-
link: `${host}/${item._id}`,
|
|
19
|
-
};
|
|
20
|
-
|
|
21
|
-
const other = await caches.tryGet(itemUrl, () => load(itemUrl, configs));
|
|
22
|
-
return Promise.resolve(Object.assign({}, single, other));
|
|
23
|
-
})
|
|
24
|
-
);
|
|
25
|
-
};
|
|
26
|
-
|
|
27
|
-
module.exports = {
|
|
28
|
-
ProcessFeed,
|
|
29
|
-
};
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const id = ctx.params.id;
|
|
6
|
-
const link = `http://www.woshipm.com/u/${id}`;
|
|
7
|
-
const response = await got.get(link);
|
|
8
|
-
const $ = cheerio.load(response.data);
|
|
9
|
-
const name = $('div.name').text();
|
|
10
|
-
|
|
11
|
-
const remark_api = `http://www.woshipm.com/__api/v1/users/${id}/bookmarks`;
|
|
12
|
-
const response_api = await got.get(remark_api);
|
|
13
|
-
const list = response_api.data.payload.value;
|
|
14
|
-
const out = await Promise.all(
|
|
15
|
-
list.map(async (info) => {
|
|
16
|
-
const title = info.title;
|
|
17
|
-
const date = info.date;
|
|
18
|
-
const itemUrl = info.permalink;
|
|
19
|
-
|
|
20
|
-
const cache = await ctx.cache.get(itemUrl);
|
|
21
|
-
if (cache) {
|
|
22
|
-
return Promise.resolve(JSON.parse(cache));
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
const response = await got.get(itemUrl);
|
|
26
|
-
const $ = cheerio.load(response.data);
|
|
27
|
-
const description = $('div.grap').html().trim();
|
|
28
|
-
|
|
29
|
-
const single = {
|
|
30
|
-
title,
|
|
31
|
-
link: itemUrl,
|
|
32
|
-
description,
|
|
33
|
-
pubDate: new Date(date).toUTCString(),
|
|
34
|
-
};
|
|
35
|
-
ctx.cache.set(itemUrl, JSON.stringify(single));
|
|
36
|
-
return Promise.resolve(single);
|
|
37
|
-
})
|
|
38
|
-
);
|
|
39
|
-
|
|
40
|
-
ctx.state.data = {
|
|
41
|
-
title: `${name}的收藏-人人都是产品经理`,
|
|
42
|
-
link,
|
|
43
|
-
item: out,
|
|
44
|
-
};
|
|
45
|
-
};
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
const got = require('@/utils/got');
|
|
2
|
-
const cheerio = require('cheerio');
|
|
3
|
-
|
|
4
|
-
module.exports = async (ctx) => {
|
|
5
|
-
const response_1 = await got('http://www.woshipm.com/__api/v1/stream-list');
|
|
6
|
-
const response_2 = await got('http://www.woshipm.com/__api/v1/stream-list/page/2');
|
|
7
|
-
const response_3 = await got('http://www.woshipm.com/__api/v1/stream-list/page/3');
|
|
8
|
-
const payload = [...response_1.data.payload, ...response_2.data.payload, ...response_3.data.payload];
|
|
9
|
-
const result = await Promise.all(
|
|
10
|
-
payload.map(async (item) => {
|
|
11
|
-
const title = item.title;
|
|
12
|
-
const link = item.permalink;
|
|
13
|
-
const guid = item.id;
|
|
14
|
-
const pubDate = new Date(item.date).toUTCString();
|
|
15
|
-
|
|
16
|
-
const single = {
|
|
17
|
-
title,
|
|
18
|
-
link,
|
|
19
|
-
guid,
|
|
20
|
-
pubDate,
|
|
21
|
-
description: '',
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
const key = 'woshipm' + guid;
|
|
25
|
-
const value = await ctx.cache.get(key);
|
|
26
|
-
|
|
27
|
-
if (value) {
|
|
28
|
-
single.description = value;
|
|
29
|
-
} else {
|
|
30
|
-
const temp = await got(link);
|
|
31
|
-
const $ = cheerio.load(temp.data);
|
|
32
|
-
single.description = $('.grap').html();
|
|
33
|
-
|
|
34
|
-
ctx.cache.set(key, single.description);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
return Promise.resolve(single);
|
|
38
|
-
})
|
|
39
|
-
);
|
|
40
|
-
ctx.state.data = {
|
|
41
|
-
title: '最新文章 - 人人都是产品经理',
|
|
42
|
-
link: 'http://www.woshipm.com/',
|
|
43
|
-
item: result,
|
|
44
|
-
};
|
|
45
|
-
};
|