Skip to content

[docs]: add docs for ignoreDefaultArgs - #2222

Merged
seanmcguire12 merged 1 commit into
mainfrom
seanmcguire/stg-2213-add-docs-for-ignoredefaultargs
Jun 9, 2026
Merged

[docs]: add docs for ignoreDefaultArgs#2222
seanmcguire12 merged 1 commit into
mainfrom
seanmcguire/stg-2213-add-docs-for-ignoredefaultargs

Conversation

@seanmcguire12

@seanmcguire12 seanmcguire12 commented Jun 9, 2026

Copy link
Copy Markdown
Member

what changed

  • adds documentation for the localBrowserLaunchOptions.ignoreDefaultArgs param
Screenshot 2026-06-09 at 1 02 20 PM

Summary by cubic

Documented localBrowserLaunchOptions.ignoreDefaultArgs and listed the default Chrome args Stagehand adds for local launches. Added examples for removing all defaults or specific args using ignoreDefaultArgs: true or a string array (STG-2213).

Written for commit 9479f03. Summary will update on new commits.

Review in cubic

@changeset-bot

changeset-bot Bot commented Jun 9, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 9479f03

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 2 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.
Architecture diagram
sequenceDiagram
    participant UserCode as User Application
    participant Stagehand as Stagehand.init()
    participant Launcher as Chrome Launcher
    participant Browser as Local Chrome
    
    UserCode->>Stagehand: new Stagehand({ localBrowserLaunchOptions })
    Stagehand->>Stagehand: Store ignoreDefaultArgs
    
    UserCode->>Stagehand: await stagehand.init()
    Stagehand->>Stagehand: Build final args list
    Note over Stagehand: Gather default Chrome args:<br/>--remote-allow-origins=*<br/>--no-first-run<br/>--no-default-browser-check<br/>--disable-dev-shm-usage<br/>--site-per-process
    
    alt ignoreDefaultArgs === true
        Stagehand->>Stagehand: Remove all default args<br/>(Stagehand + Chrome Launcher defaults)
    else ignoreDefaultArgs is string[]
        Stagehand->>Stagehand: Filter out matching default args<br/>by exact string comparison
    else ignoreDefaultArgs === false (default)
        Stagehand->>Stagehand: Keep all default args
    end
    
    Stagehand->>Stagehand: Prepend remaining default args<br/>before user-supplied args
    Stagehand->>Launcher: launch({ args: finalArgs, ... })
    Launcher->>Browser: Start Chrome with filtered args
    Browser-->>Launcher: Browser instance
    Launcher-->>Stagehand: Browser & CDP connection
    Stagehand-->>UserCode: Ready for automation
Loading

Re-trigger cubic

@mintlify

mintlify Bot commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
stagehand 🟢 Ready View Preview Jun 9, 2026, 8:07 PM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@seanmcguire12
seanmcguire12 merged commit 9a1c06a into main Jun 9, 2026
11 checks passed
felipeofdev-ai pushed a commit to felipeofdev-ai/stagehand that referenced this pull request Aug 4, 2026
# what changed
- adds documentation for the
`localBrowserLaunchOptions.ignoreDefaultArgs` param

<img width="1203" height="713" alt="Screenshot 2026-06-09 at 1 02 20 PM"
src="https://github.com/user-attachments/assets/5f3b2ff1-d8d1-41b9-81f3-4c6b9dcbea48"
/>


<!-- This is an auto-generated description by cubic. -->
---
## Summary by cubic
Documented `localBrowserLaunchOptions.ignoreDefaultArgs` and listed the
default Chrome args Stagehand adds for local launches. Added examples
for removing all defaults or specific args using `ignoreDefaultArgs:
true` or a string array (STG-2213).

<sup>Written for commit 9479f03.
Summary will update on new commits.</sup>

<a
href="https://cubic.dev/pr/browserbase/stagehand/pull/2222?utm_source=github"
target="_blank" rel="noopener noreferrer"
data-no-image-dialog="true"><picture><source
media="(prefers-color-scheme: dark)"
srcset="https://cubic.dev/buttons/review-in-cubic-dark.svg"><source
media="(prefers-color-scheme: light)"
srcset="https://cubic.dev/buttons/review-in-cubic-light.svg"><img
alt="Review in cubic"
src="https://cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a>

<!-- End of auto-generated description by cubic. -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants