Elements

bl fill

Clear an input field and type new text

Clear an input field and type new text

Usage

bl fill <selector> <text> [OPTIONS]

Arguments

ArgumentDescription
&lt;selector&gt;CSS selector or @ref of the input field
&lt;text&gt;Text to type into the field after clearing it

Options

OptionDescription
--nth <value>Select the 0-based Nth match of the selector (default: first). Mutually exclusive with --last.
--lastSelect the last match of the selector. Mutually exclusive with --nth.
--headlessHide browser window (visible by default)
--jsonOutput as JSON
--session <value>Run this command in the named session (env: BL_SESSION; default: "default")

Global options

OptionDescription
-v, --verboseEnable debug logging

Examples

bl fill "input[name=email]" "user@example.com"
# Clear the field and type new value

bl fill "#search" "browserlane"
# Replace search field contents

bl fill ".field" "x" --nth 1
# Fill the second matching field (0-based)

On this page