prefix property
final
A function called to determine the prefix for a specific message.
This function should return a Pattern that should match the start of the message content if it begins with the prefix.
If this function is null
, message commands are disabled.
For example, for a prefix of !
:
(_) => '!'
Or, for either !
or $
as a prefix:
(_) => RegExp(r'!|\$')
You might also be interested in:
Implementation
final FutureOr<Pattern> Function(MessageCreateEvent)? prefix;