yr.option
option(
label: str,
description: str | None = None,
) → OptionCreate an Option instance.
Parameters
label
type: str
The visible label for the option.
description
type: str | None = None
Optional descriptive text.
Returns
type: Option
An Option instance with given label and description.
Examples
Describe possible destinations for a day trip:
import yera as yr
museum = yr.option(
"Museum",
"Spend the afternoon viewing art.",
)
park = yr.option(
"Park",
"Walk outdoors if the weather is fine.",
)