export class MessageMentions<InGuild extends boolean = boolean>
Keeps track of mentions in a Message.
readonlyCollection<Snowflake, Channel> channels :
Any channels that were mentioned Order as they appear first in the message content
statictypeof FormattingPatterns.Channel ChannelsPattern :
A regular expression that matches channel mentions like <#222079895583457280>
. The id
group property is present on the exec
result of this expression.
readonlyClient client :
Collection<Snowflake, CrosspostedChannel> crosspostedChannels :
A collection of crossposted channels Order as received from the API, not as they appear in the message content
boolean everyone :
Whether @everyone
or @here
were mentioned
staticRegExp EveryonePattern :
A regular expression that matches @everyone
and @here
. The mention
group property is present on the exec
result of this expression.
readonlyIf<InGuild, Collection<Snowflake, GuildMember>> members :
Any members that were mentioned (only in Guilds) Order as received from the API, not as they appear in the message content
readonlyCollection<Snowflake, User> parsedUsers :
Any user mentions that were included in the message content Order as they appear first in the message content
Collection<Snowflake, Role> roles :
Any roles that were mentioned Order as received from the API, not as they appear in the message content
statictypeof FormattingPatterns.Role RolesPattern :
A regular expression that matches role mentions like <@&297577916114403338>
. The id
group property is present on the exec
result of this expression.
Collection<Snowflake, User> users :
Any users that were mentioned Order as received from the API, not as they appear in the message content
statictypeof FormattingPatterns.User UsersPattern :
A regular expression that matches user mentions like <@81440962496172032>
. The id
group property is present on the exec
result of this expression.
hasdata: UserResolvable | RoleResolvable | ChannelResolvableoptions?: MessageMentionsHasOptions) : boolean (
Checks if a user, guild member, thread member, role, or channel is mentioned. Takes into account user mentions, role mentions, channel mentions, replied user mention, and @everyone
/@here
mentions.