Closed owengombas closed 4 years ago
Ah, thank you!
@OwenCalvin There doesn't happen to be a built in way to generate a list of the available commands dynamically? Managed to do it with some introspection on the MetadataStorage instance, but it seems like it would be a common use case. I've been thinking that a @Description
decorator would be nice to add a short description of each command. What do you think?
Thank's for this feedback I'm going to add this feature in like 1 hour, you could normaly be able to access to the commands using Client.getCommands(forPrefix?: string)
And yes I'll add a description parameter to the @Command
decorator :)
So I made an update (version 2.0.2) wich is available on npm
(simply run an npm update
command).
The documentation is here: https://github.com/OwenCalvin/discord.ts#the-command-parameters https://github.com/OwenCalvin/discord.ts#retrieve-the-commands
Amazing! Will update later today :D
The
NotBot
Guard isn't required with the@Command
decorator. The decorator check it for you ;)