Skip to main content

Namespace: EmbedJsx

@sapphire/embed-jsx.EmbedJsx

The namespace to import for embed-jsx

example

import { EmbedJsx } from '@sapphire/embed-jsx';

const embed = (
<embed color="RED">
<title>New Embed</title>
<description>Hello!</description>
</embed>
)

Functions

make

โ–ธ make(type, ...data): EmbedData | MessageEmbed

The behind the scenes function that TS uses to turn JSX into proper JS

Parameters

NameTypeDescription
type"embed" | "title" | "field" | "timestamp" | "footer" | "description" | "image" | "thumbnail" | "author"The embed type being created
...dataEmbedInformation | EmbedInitialInformationThe data emitted along with

Returns

EmbedData | MessageEmbed

The embed defined with jsx

Defined in

projects/utilities/packages/embed-jsx/src/lib/EmbedJsx.ts:82