[Docs] add go snippets to reference pages - #2667
Conversation
|
There was a problem hiding this comment.
cubic analysis
Review completed against the latest diff
Linked issue analysis
Linked issue: STG-2801: Add Go snippets to missing reference docs
| Status | Acceptance criteria | Notes |
|---|---|---|
| ✅ | Add Go snippets to reference/locator | The PR adds a section with multiple Go examples (Quick start, Click, Hover, Fill, etc.) to packages/docs/v4/reference/locator.mdx. |
| ✅ | Add Go snippets to reference/page | The PR adds a section with many Go examples for page methods (Goto, Click, Hover, Screenshot, etc.) to packages/docs/v4/reference/page.mdx. |
| ✅ | Add Go snippets to reference/context | The PR adds a section documenting BrowserContext methods (Pages, NewPage, Cookies, ClearCookies, etc.) in packages/docs/v4/reference/context.mdx. |
| ✅ | Add Go snippets to reference/stagehand | The PR adds a section covering Stagehand client and methods (Create, Act, Observe, Extract, ExperimentalBatch, etc.) in packages/docs/v4/reference/stagehand.mdx. |
| ✅ | Add Go snippets to reference/clipboard | The PR adds a section with Go examples for clipboard methods (ReadText, WriteText, Clear, Paste, Copy, Cut) in packages/docs/v4/reference/clipboard.mdx. |
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
e40b950 to
d2475b2
Compare
There was a problem hiding this comment.
All reported issues were addressed across 3 files (changes from recent commits).
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
There was a problem hiding this comment.
All reported issues were addressed across 5 files (changes from recent commits).
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
There was a problem hiding this comment.
All reported issues were addressed across 1 file (changes from recent commits).
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
why
Missing go snippets in the reference files. Also adding the vitest change so this is prevented in the future
what changed
test plan
Summary by cubic
Adds Go snippets to the missing v4 reference pages and expands the
vitestdocs checker to keep TypeScript, Python, and Go in sync. Completes Linear STG-2801 by adding Go tolocator,page,context,stagehand, andclipboard.New Features
reference/locator,reference/page,reference/context,reference/stagehand,reference/clipboard; examples showdefercleanup and includePage.URL()usage. Strengthened thevitestchecker for Go: parses Go source to validate shared SDK surface coverage, exact method headings, direct parameter lists,responsemembers, and verbatim Go ParamField types; enforces exactly one tab per SDK language per page and flags missing language snippets.Bug Fixes
Response.HeaderValue()to show(string, bool, error)and clarified header lookup behavior.Clipboard.Pasteshortcut options for readability.Written for commit 0f34006. Summary will update on new commits.