爱意满满的作品展示区。
zhshch

Goribot - 简洁的 Golang 爬虫框架

  •  
  •   zhshch · Oct 2, 2019 · 6407 views
    This topic created in 2609 days ago, the information mentioned may be changed or developed.

    https://github.com/zhshch2002/goribot

    B 站视频爬虫栗子

    一个简单的栗子:

    package main
    
    import (
        "fmt"
        "github.com/zhshch2002/goribot"
    )
    
    func main() {
        s := goribot.NewSpider()
        s.NewTask(
            goribot.MustNewGetReq("https://httpbin.org/get?Goribot%20test=hello%20world"),
            func(ctx *goribot.Context) {
                fmt.Println("got resp data", ctx.Text)
            })
        s.Run()
    }
    
    3 replies  •  2019-10-09 10:44:23 +08:00
    electronic
    electronic
    Oct 6, 2019 via Android
    1
    支持
    zhshch
    zhshch
    OP
    Oct 8, 2019 via Android
    2
    @electronic thx

    好几个收藏 1 个回复😂
    ango
    ango
    Oct 9, 2019
    3
    关注一下~
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   4374 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 31ms · UTC 09:20 · PVG 17:20 · LAX 01:20 · JFK 04:20
    ♥ Do have faith in what you're doing.