Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

HTMLOptionElement

interface HTMLOptionElement extends HTMLElement {
defaultSelected: boolean;
disabled: boolean;
readonly form: HTMLFormElement | null;
readonly index: number;
label: string;
selected: boolean;
text: string;
value: string;
addEventListener<K extends keyof HTMLElementEventMap>(
type: K,
listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any,
options?: boolean | AddEventListenerOptions,
): void;
addEventListener(
type: string,
options?: boolean | AddEventListenerOptions,
): void;
removeEventListener<K extends keyof HTMLElementEventMap>(
type: K,
listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any,
options?: boolean | EventListenerOptions,
): void;
removeEventListener(
type: string,
options?: boolean | EventListenerOptions,
): void;
}
var HTMLOptionElement: {
prototype: HTMLOptionElement;
}
;

§Extends

§Properties

§
defaultSelected: boolean
[src]

Sets or retrieves the status of an option.

§
disabled: boolean
[src]
§
readonly form: HTMLFormElement | null
[src]

Retrieves a reference to the form that the object is embedded in.

§
readonly index: number
[src]

Sets or retrieves the ordinal position of an option in a list box.

§
label: string
[src]

Sets or retrieves a value that you can use to implement your own label functionality for the object.

§
selected: boolean
[src]

Sets or retrieves whether the option in the list box is the default item.

§
text: string
[src]

Sets or retrieves the text string specified by the option tag.

§
value: string
[src]

Sets or retrieves the value which is returned to the server when the form control is submitted.

§Methods

§
addEventListener<K extends keyof HTMLElementEventMap>(
type: K,
listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any,
options?: boolean | AddEventListenerOptions,
): void
[src]
§
addEventListener(
type: string,
options?: boolean | AddEventListenerOptions,
): void
[src]
§
removeEventListener<K extends keyof HTMLElementEventMap>(
type: K,
listener: (this: HTMLOptionElement, ev: HTMLElementEventMap[K]) => any,
options?: boolean | EventListenerOptions,
): void
[src]
§
removeEventListener(
type: string,
options?: boolean | EventListenerOptions,
): void
[src]