Embed with pages as parameter
Greetings to everyone.
This idea is not new, but has been long since no one talked about it. Embeds should have a parameter called something like 'setMaxFields', as other parameters that exist like .setPicture, .setAuthor, addField etc.
How would look the code?
So you make the Embed:
const embed = new Discord.MessageEmbed()
and then you add the parameters, in this case would be
.setMaxFields(5)
How does work?
How does work?
Imagine we have a total of 15 fields added to the Embed and we set up the maximum of fields per page as 5, it will separate the Embed in 3 pages with a total of 5 fields per page (buttons will be under fields to go forward or back on pages).
Why this change should see the light?
It's pretty messy to make this system for each command that have a lot of fields, and you have to use different parameters to make it. It will make the things easier to bot developers.
I hope you liked my idea, don't forget that every opinion is relevant and you could even improve my idea.
Why this change should see the light?
It's pretty messy to make this system for each command that have a lot of fields, and you have to use different parameters to make it. It will make the things easier to bot developers.
I hope you liked my idea, don't forget that every opinion is relevant and you could even improve my idea.
Have a nice day, Kashix.
1
-
This seems more like a job for whatever library you're using (I'm assuming Discord.js?) rather than the API itself. Maybe make a suggestion over there?
0
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
1 Kommentar