SelectMenuOption

Create a select menu option

Constructor

new SelectMenuOption()

Example
const { SelectMenuOption } = require("interactions.js");

const select = new SelectMenuOption()
.setLabel('label') // Set the label of the select menu option
.setValue('value') // Set the value of the select menu option
.setDescription('description') // Set the description of the select menu option
.setEmoji('🎍') // Set the emoji of the select menu option
.setDefault(true) // Set the default of the select menu option

Methods

setDefault(defaultState) → {SelectMenuOption}

set the default state of the option

Parameters:
NameTypeDescription
defaultStateboolean
Returns:
Type: 
SelectMenuOption

setDescription(description) → {SelectMenuOption}

Set the description of the select menu option

Parameters:
NameTypeDescription
descriptionstring
Returns:
Type: 
SelectMenuOption

setEmoji(emoji) → {SelectMenuOption}

Set the emoji of the select menu option

Parameters:
NameTypeDescription
emojiobject
Returns:
Type: 
SelectMenuOption

setLabel(label) → {SelectMenuOption}

Set the label of the select menu option

Parameters:
NameTypeDescription
labelstring
Returns:
Type: 
SelectMenuOption

setValue(value) → {SelectMenuOption}

Set the value of the select menu option

Parameters:
NameTypeDescription
valuestring
Returns:
Type: 
SelectMenuOption