mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-12 09:33:32 +01:00
refactor: removed code and split options (#5918)
Co-authored-by: Jan <66554238+vaporox@users.noreply.github.com> BREAKING CHANGE: Removed `APIMessage#split` BREAKING CHANGE: Removed `MessageEditOptions#code` BREAKING CHANGE: Removed `BaseMessageOptions#code` BREAKING CHANGE: Removed `BaseMessageOptions#split`
This commit is contained in:
@@ -55,6 +55,16 @@ class Util {
|
||||
return out;
|
||||
}
|
||||
|
||||
/**
|
||||
* Options for splitting a message.
|
||||
* @typedef {Object} SplitOptions
|
||||
* @property {number} [maxLength=2000] Maximum character length per message piece
|
||||
* @property {string|string[]|RegExp|RegExp[]} [char='\n'] Character(s) or Regex(s) to split the message with,
|
||||
* an array can be used to split multiple times
|
||||
* @property {string} [prepend=''] Text to prepend to every piece except the first
|
||||
* @property {string} [append=''] Text to append to every piece except the last
|
||||
*/
|
||||
|
||||
/**
|
||||
* Splits a string into multiple chunks at a designated character that do not exceed a specific length.
|
||||
* @param {string} text Content to split
|
||||
|
||||
Reference in New Issue
Block a user