How to show a modal after a reply?

In this command, the bot reply (ephemeral) to the slash command with a button, how to show a modal when this the user interact with this button? (asking because i received the interaction already replied error using await interaction.showModal() in the component file of the button.
4 Replies
d.js toolkit
d.js toolkit14mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button! - Marked as resolved by OP
Syjalo
Syjalo14mo ago
Use .showModal() on the button interaction
Massicraft
MassicraftOP14mo ago
so ButtonInteraction.showModal() ?
Syjalo
Syjalo14mo ago
Yes, if you have defined the interaction as so ButtonInteraction
Want results from more Discord servers?
Add your server