FIND YOUR NEXT FEW LINES

Results for “option”

Small, practical examples. Search by task or narrow things down below.

95 snippets foundClear filters
jQueryTraversal & selection

Read checked options

Collect checked checkbox values with jQuery map and get.

jQuery✓ Tested
jQueryForm serialization & state

Remove an optional attribute entirely

jQuery: removeAttr removes the attribute instead of setting a string that might still activate it.

jQuery✓ Tested
PowerShellHashtables & object records

Remove an optional hashtable entry

PowerShell: Remove changes the map in place without changing unrelated entries.

PowerShell✓ Tested
GoStrings & text

Remove an optional prefix

Remove an optional prefix using a complete Go program with explicit sample inputs.

Go✓ Tested
ReactGetting Started

Render an optional notice

Render an optional notice with a small React component and explicit browser behavior.

React✓ Tested
ReactGetting Started

Render nothing from an optional component

Render nothing from an optional component with a small React component and explicit browser behavior.

React✓ Tested
C++Ownership & optional values

Represent an absent result with optional

C++: value_or supplies a default without requiring a sentinel inside the value domain.

C++✓ Tested
jQueryForm serialization & state

Set several selected options

jQuery: Passing an array to val selects matching values in a multiple select.

jQuery✓ Tested
CSSInteraction selectors

Style content associated with a checked option

CSS: The adjacent-sibling selector connects a checked control with its following label text.

CSS✓ Tested
JavaRecords & reliable control flow

Transform an optional value

Java: Use Optional.map and orElse to transform a possibly absent result.

Java✓ Tested
RustErrors & optional values

Transform an optional value

Transform an optional value in a complete Rust program using the standard library.

Rust✓ Tested
RustErrors & optional values

Transpose an optional parsing result

Transpose an optional parsing result in a complete Rust program using the standard library.

Rust✓ Tested