chrome

package
v3.6.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 21, 2021 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHeadless

func NewHeadless(ctx context.Context, starturl string, extra ...chromedp.ExecAllocatorOption) (context.Context, error)

NewHeadless 创建headless chrome实例 chromedp内部有自己的超时设置,你也可以通过ctx来设置更短的超时

Types

type Chrome

type Chrome struct {
	Browser *cr.Browser
	*collector.Base
}

func New

func New() *Chrome

func (*Chrome) Close

func (s *Chrome) Close() error

func (*Chrome) Description

func (s *Chrome) Description() string

func (*Chrome) Do

func (s *Chrome) Do(pageURL string, data echo.Store) ([]byte, error)

func (*Chrome) Name

func (s *Chrome) Name() string

func (*Chrome) Start

func (s *Chrome) Start(opt echo.Store) (err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL