mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 16:43:31 +01:00
feat: add subtext formatter (#10400)
Co-authored-by: Jiralite <33201955+Jiralite@users.noreply.github.com>
This commit is contained in:
@@ -569,6 +569,16 @@ export function unorderedList(list: RecursiveArray<string>): string {
|
||||
return listCallback(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* Formats the content into a subtext.
|
||||
*
|
||||
* @typeParam Content - This is inferred by the supplied content
|
||||
* @param content - The content to wrap
|
||||
*/
|
||||
export function subtext<Content extends string>(content: Content): `-# ${Content}` {
|
||||
return `-# ${content}`;
|
||||
}
|
||||
|
||||
/**
|
||||
* Formats a date into a short date-time string.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user