@ulpi/browse

Snapshot & Find

Accessibility snapshots with @refs, semantic element locators

4 commands

snapshot

browse snapshot [flags]

Accessibility tree with @ref assignments

Flags

-iInteractive elements only
-fFull indented tree
-VViewport only
-cCompact
-CCursor-interactive
-d NLimit depth
-s selScope to selector

Get interactive elements

$ browse snapshot -i
@e1 [button] "Submit"
@e2 [link] "Home"
@e3 [textbox] "Email"

find

browse find <method> <query>

Find elements by role, text, label, testid, etc.

Find by role

$ browse find role button

Find by text

$ browse find text "Submit"

snapshot-diff

browse snapshot-diff

Diff current vs previous accessibility snapshot

Compare snapshots

$ browse snapshot-diff

count

browse count <selector>

Count elements matching selector

Count results

$ browse count ".result"
12

On this page