$codeblock
Returns the content input in markdown codeblock with optional syntax highlighting.

FUNCTION USAGE

    $codeblock[input]
    $codeblock[input;syntax]

Properties:

input - The message to be placed into codeblock. syntax - Define as true or yes to add javascript syntax highlighting to the codeblock message. Otherwise, the function will simply return message in plain codeblock.

Example 1: Inputs "Hello!" into a codeblock with a syntax highlighting.

1
bot.Command({
2
name: "code",
3
code: `
4
$codeblock[Hello!;yes]
5
`
6
})
Copied!

Example 2: Inputs "hello" into a codeblock.

1
bot.Command({
2
name: "code",
3
code: `
4
$codeblock[Hello!]
5
`
6
})
Copied!
Last modified 3mo ago
Copy link
Contents
Properties: