src/Concerns/Selection.php
protected function option(
        string $display,
        string $value,
        $selected,
        array $attributes = [],
        array $optgroups = []
    ): Htmlable {
        $selected = $this->getSelectedValue($value, $selected);

        $options = ['value' => $value, 'selected' => $selected] + $attributes;

        return $this->toHtmlString(\sprintf(
            '<option%s>%s</option>',
            $this->getHtmlBuilder()->attributes($options),
            $this->entities($display)
        ));
    }
protected function option(
        string $display,
        string $value,
        $selected,
        array $attributes = [],
        array $optgroups = []
    ): Htmlable {
        $selected = $this->getSelectedValue($value, $selected);

        $options = ['value' => $value, 'selected' => $selected] + $attributes;

        return $this->toHtmlString(\sprintf(
            '<option%s>%s</option>',
            $this->getHtmlBuilder()->attributes($options),
            $this->entities($display)
        ));
    }
Create a select element option.

@param  string  $display
@param  string  $value
@param  string|array|\Illuminate\Contracts\Support\Arrayable|bool  $selected
@param  array  $attributes
@param  array  $optgroups

@return \Illuminate\Contracts\Support\Htmlable