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

HTMLTableElement

Provides special properties and methods (beyond the regular HTMLElement object interface it also has available to it by inheritance) for manipulating the layout and presentation of tables in an HTML document.

interface HTMLTableElement extends HTMLElement {
align: string;
bgColor: string;
border: string;
caption: HTMLTableCaptionElement | null;
cellPadding: string;
cellSpacing: string;
frame: string;
rules: string;
summary: string;
width: string;
addEventListener<K extends keyof HTMLElementEventMap>(
type: K,
listener: (this: HTMLTableElement, ev: HTMLElementEventMap[K]) => any,
options?: boolean | AddEventListenerOptions,
): void;
addEventListener(
type: string,
options?: boolean | AddEventListenerOptions,
): void;
createCaption(): HTMLTableCaptionElement;
createTBody(): HTMLTableSectionElement;
createTFoot(): HTMLTableSectionElement;
createTHead(): HTMLTableSectionElement;
deleteCaption(): void;
deleteRow(index: number): void;
deleteTFoot(): void;
deleteTHead(): void;
insertRow(index?: number): HTMLTableRowElement;
removeEventListener<K extends keyof HTMLElementEventMap>(
type: K,
listener: (this: HTMLTableElement, ev: HTMLElementEventMap[K]) => any,
options?: boolean | EventListenerOptions,
): void;
removeEventListener(
type: string,
options?: boolean | EventListenerOptions,
): void;
}
var HTMLTableElement: {
prototype: HTMLTableElement;
}
;

§Extends

§Properties

§
align: string
[src]

Sets or retrieves a value that indicates the table alignment.

§
bgColor: string
[src]
§
border: string
[src]

Sets or retrieves the width of the border to draw around the object.

§

Retrieves the caption object of a table.

§
cellPadding: string
[src]

Sets or retrieves the amount of space between the border of the cell and the content of the cell.

§
cellSpacing: string
[src]

Sets or retrieves the amount of space between cells in a table.

§
frame: string
[src]

Sets or retrieves the way the border frame around the table is displayed.

§

Sets or retrieves the number of horizontal rows contained in the object.

§
rules: string
[src]

Sets or retrieves which dividing lines (inner borders) are displayed.

§
summary: string
[src]

Sets or retrieves a description and/or structure of the object.

§

Retrieves a collection of all tBody objects in the table. Objects in this collection are in source order.

§

Retrieves the tFoot object of the table.

§

Retrieves the tHead object of the table.

§
width: string
[src]

Sets or retrieves the width of the object.

§Methods

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

Creates an empty caption element in the table.

§

Creates an empty tBody element in the table.

§

Creates an empty tFoot element in the table.

§

Returns the tHead element object if successful, or null otherwise.

§
deleteCaption(): void
[src]

Deletes the caption element and its contents from the table.

§
deleteRow(index: number): void
[src]

Removes the specified row (tr) from the element and from the rows collection.

@param index

Number that specifies the zero-based position in the rows collection of the row to remove.

§
deleteTFoot(): void
[src]

Deletes the tFoot element and its contents from the table.

§
deleteTHead(): void
[src]

Deletes the tHead element and its contents from the table.

§
insertRow(index?: number): HTMLTableRowElement
[src]

Creates a new row (tr) in the table, and adds the row to the rows collection.

@param index

Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.

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