Function: isTextBasedChannel()
isTextBasedChannel(
channel
:Nullish
|ChannelTypes
): channel is DMChannel | PartialDMChannel | NewsChannel | TextChannel | PublicThreadChannel<boolean> | PrivateThreadChannel | VoiceChannel
Checks whether a given channel is a TextBasedChannelTypes. This means it has a send
method.
Parameters
Parameter | Type | Description |
---|---|---|
channel | Nullish | ChannelTypes | The channel to check. |
Returns
channel is DMChannel | PartialDMChannel | NewsChannel | TextChannel | PublicThreadChannel<boolean> | PrivateThreadChannel | VoiceChannel
Defined in
projects/utilities/packages/discord.js-utilities/src/lib/type-guards.ts:158