Documentation
¶
Overview ¶
Package browser — multi-backend browser automation engine. Backends: chrome (built-in), playwright (plugin). The builtin browser.go delegates here for extensibility.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Browser ¶
type Browser interface {
// Name returns the backend name.
Name() string
// NewPage opens a new page/tab.
NewPage(ctx context.Context) (Page, error)
// Close shuts down the browser.
Close() error
}
Browser opens and manages browser instances.
type Page ¶
type Page interface {
Screenshot(ctx context.Context) ([]byte, error)
Text(ctx context.Context) (string, error)
Click(ctx context.Context, selector string) error
Type(ctx context.Context, selector, value string) error
Eval(ctx context.Context, js string) (string, error)
Close() error
}
Page represents a browser page/tab.
Click to show internal directories.
Click to hide internal directories.