Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose os.Process from the Browser #737

Merged
merged 7 commits into from Apr 30, 2021
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions browser.go
Expand Up @@ -310,6 +310,11 @@ func (b *Browser) run(ctx context.Context) {
}
}

// Pid returns the browser process ID
func (b *Browser) Pid() int {
msoap marked this conversation as resolved.
Show resolved Hide resolved
return b.process.Pid
ZekeLu marked this conversation as resolved.
Show resolved Hide resolved
}

// BrowserOption is a browser option.
type BrowserOption = func(*Browser)

Expand Down