class ButtonComponent

export class ButtonComponent extends Component<APIButtonComponent>

Represents a button component

readonly
customId : string | null

The custom id of this button (only defined on non-link buttons)

readonly
data : Readonly<APIButtonComponent>

The API data associated with this component

Inherited from: Component

readonly
disabled : boolean

Whether this button is disabled

readonly
emoji : APIMessageComponentEmoji | null

The emoji used in this button

readonly
label : string | null

The label of this button

readonly
style : ButtonStyle

The style of this button

readonly
type : APIButtonComponent['type']

The type of the component

Inherited from: Component

readonly
url : string | null

The URL of this button (only defined on link buttons)

equals(
other: this | APIButtonComponent
) : boolean

Whether or not the given components are equal

Inherited from: Component

toJSON() : APIButtonComponent

Returns the API-compatible JSON for this component

Inherited from: Component