DiscordLua
discorddiscord
v1.2.4
Install

ComponentType

Enum
On this page

discord.ComponentType lists the named constants for this enumeration. Prefer these names over hardcoded literals.

Values

discord.ComponentType.ActionRow
1
Action Row. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.Button
2
Button. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.StringSelect
3
String Select. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.TextInput
4
Text Input. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.UserSelect
5
User Select. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.RoleSelect
6
Role Select. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.MentionableSelect
7
Mentionable Select. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.ChannelSelect
8
Channel Select. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.Section
9
Section. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.TextDisplay
10
Text Display. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.Thumbnail
11
Thumbnail. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.MediaGallery
12
Media Gallery. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.File
13
File. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.Separator
14
Separator. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.ContentInventoryEntry
16
Content Inventory Entry. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.Container
17
Container. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.Label
18
Label. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.FileUpload
19
File Upload. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.RadioGroup
21
Radio Group. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.CheckboxGroup
22
Checkbox Group. Use the symbolic name in bot code rather than the raw value.
discord.ComponentType.Checkbox
23
Checkbox. Use the symbolic name in bot code rather than the raw value.

Usage

Read members as discord.ComponentType.Name. Do not hard-code numeric literals when a symbolic name exists.

Example

lua
local discord = require("discord")
print(discord.ComponentType.ActionRow)
Search Ctrl K Navigate Open Esc