Abstract

BaseSelectMenuBuilder

export declare abstract class BaseSelectMenuBuilder<SelectMenuType extends APISelectMenuComponent> extends ComponentBuilder<SelectMenuType>
export declare abstract class BaseSelectMenuBuilder<SelectMenuType extends APISelectMenuComponent> extends ComponentBuilder<SelectMenuType>
The base select menu builder that contains common symbols for select menu builders.

Extends

ComponentBuilder<SelectMenuType>
NameConstraintsOptionalDefaultDescription
SelectMenuTypeAPISelectMenuComponentNoThe type of select menu this would be instantiated for.
Readonly
data:Partial<SelectMenuType>
The API data associated with this component.
Inherited from ComponentBuilder
setCustomId(customId):this
Sets the custom id for this select menu.
NameTypeOptionalDescription
customIdstringNoThe custom id to use
setDisabled(disabled?):this
Sets whether this select menu is disabled.
NameTypeOptionalDescription
disabledbooleanYesWhether this select menu is disabled
setMaxValues(maxValues):this
Sets the maximum values that must be selected in the select menu.
NameTypeOptionalDescription
maxValuesnumberNoThe maximum values that must be selected
setMinValues(minValues):this
Sets the minimum values that must be selected in the select menu.
NameTypeOptionalDescription
minValuesnumberNoThe minimum values that must be selected
setPlaceholder(placeholder):this
Sets the placeholder for this select menu.
NameTypeOptionalDescription
placeholderstringNoThe placeholder to use
toJSON():SelectMenuType
Serializes this builder to API-compatible JSON data.
Remarks
This method runs validations on the data before serializing it. As such, it may throw an error if the data is invalid.