Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module.exports = {
- data: new SlashCommandBuilder()
- .setName('embedcreator')
- .setDescription('This creates a custom embed')
- .addStringOption(Option =>
- Option
- .setName('author-name')
- .setDescription('This is the name of author of the embed')
- .setRequired(false)
- )
- // ... the rest of your command options
- async execute(interaction) {
- const { options } = interaction;
- // Here we declare the Author Title string.
- const authorTitle = options.getString('author-name')
- // ... the rest of your getString() variables
- const embed = new EmbedBuilder()
- .setAuthor({
- // Here we need a string for the name, so authorTitle is passed in.
- name: authorTitle
- // ... your other author options
- })
- // ... the rest of your embed options
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment