headless

package module
v0.0.0-...-a5c1a77 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2023 License: Unlicense Imports: 13 Imported by: 0

README

headless

Headless Chrome browser controlled with Go.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewURL

func NewURL(urlstr string) *url.URL

Types

type Browser

type Browser struct {
	Human *Human
	// contains filtered or unexported fields
}

Browser wraps the headless Chrome instance.

func NewBrowser

func NewBrowser(remote string) *Browser

func (*Browser) Close

func (browser *Browser) Close()

func (*Browser) Extract

func (browser *Browser) Extract(sel string) string

func (*Browser) Navigate

func (browser *Browser) Navigate(url string)

func (*Browser) Spider

func (browser *Browser) Spider(urlstr string)

type Human

type Human struct {
	// contains filtered or unexported fields
}

func NewHuman

func NewHuman(ctx context.Context) *Human

func (*Human) Click

func (human *Human) Click(sel string)

func (*Human) Type

func (human *Human) Type(sel, str string)

func (*Human) Wait

func (human *Human) Wait()

Jump to

Keyboard shortcuts

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