Documentation ¶
Overview ¶
Index ¶
- Variables
- func EnableLifeCycleEvents() chromedp.Action
- func IgnoreCacheReload(timeout time.Duration) chromedp.NavigateAction
- func Navigate(urlstr interface{}, timeout time.Duration) chromedp.NavigateAction
- func RestoreCookies(filename interface{}, filters ...func(*network.Cookie) bool) chromedp.Action
- func SaveCookies(filename interface{}, maps ...func(*network.Cookie)) chromedp.Action
- func Screenshot(filename interface{}) chromedp.Action
- func URL(endpoint, path string, val ...*string) fmt.Stringer
- func WaitForTime(t time.Time) chromedp.Action
- func WaitInput(r io.Reader, message string, expected ...string) chromedp.Action
- func WaitLoaded(timeout time.Duration) chromedp.Action
- func WaitResponse(urlstr interface{}, timeout time.Duration, acts ...chromedp.Action) chromedp.Action
Examples ¶
Constants ¶
This section is empty.
Variables ¶
var ( // ErrCanceledByUser is an error because of canceled by user. ErrCanceledByUser = errors.New("canceled by user") )
Functions ¶
func EnableLifeCycleEvents ¶
EnableLifeCycleEvents enables life cycle events.
func IgnoreCacheReload ¶
func IgnoreCacheReload(timeout time.Duration) chromedp.NavigateAction
IgnoreCacheReload is an action that reloads the current page without cache.
func Navigate ¶
func Navigate(urlstr interface{}, timeout time.Duration) chromedp.NavigateAction
Navigate is an action that navigates the current frame.
urlstr can be specified by string, string pointer or fmt.Stringer.
func RestoreCookies ¶ added in v1.1.0
RestoreCookies is an action that restores cookies from json lines file.
filename can be specified by string, string pointer or fmt.Stringer.
func SaveCookies ¶ added in v1.1.0
SaveCookies is an action that saves cookies as json lines file.
filename can be specified by string, string pointer or fmt.Stringer.
func Screenshot ¶
Screenshot is an action that takes a screenshot of the entire browser viewport and save as image file.
Note: this will override the viewport emulation settings.
This function is based on https://github.com/chromedp/examples
filename can be specified by string, string pointer or fmt.Stringer.
func WaitForTime ¶
WaitForTime is an action that waits until for time.
func WaitLoaded ¶
WaitLoaded is an action that waits until load event fired or timeout exceeded.
Types ¶
This section is empty.