Easy Embed Maker
๐งก An easy discord embed message maker for newbies, just a function, try it yourself!
Installation
$ npm install dann-embed
Quick Example
const { Client, Intents } = require('discord.js');
const client = new Client({ intents: [Intents.FLAGS.GUILDS] });
const Embed = require('dann-embed');
client.on('ready', () => {
console.log(`Logged in as ${client.user.tag}!`);
});
client.on('messageCreate', async message => {
if (message.content === '!ping') {
Embed(message).description("Pong!").send();
}
});
client.login('token');
Main Function
const Embed = require('dann-embed');
Embed(message); // Object => {embed: MessageEmbedClass}
Message Class
Class Functions
.author(name, iconUrl)
.title(name)
PARAMETER |
TYPE |
OPTIONAL |
name |
string |
|
.field(name, value, inline)
.description(text)
PARAMETER |
TYPE |
OPTIONAL |
text |
string |
|
.color(hexColor)
PARAMETER |
TYPE |
OPTIONAL |
hexColor |
string |
|
.time(timestamp)
.thumbnail(imageLink)
PARAMETER |
TYPE |
OPTIONAL |
imageLink |
string |
|
.image(imageLink)
PARAMETER |
TYPE |
OPTIONAL |
imageLink |
string |
|
.footer(name, iconUrl)
.send(channel)
Join to us!