#feat: application commands decorators

1 messages · Page 1 of 1 (latest)

tardy willow
sacred shadow
#

<@&737143732939259944> can we get a second review here?

sacred shadow
#

<@&737143732939259944>

tardy willow
#

Do i also need to provide a registry option param?

(builder: SlashCommandBuilder, command: ThisType<CMD> & CMD, options: ApplicationCommandRegistryRegisterOptions)

for people who wants to provide their own ids

sacred shadow
#

Erm

#

Might as well if it's not too much trouble

tardy willow
#

Sure, I will get it done later

tardy willow
#

erm i realized that it's not possible to put registry options param in the callback, so it be in a second param. which would be like this

zinc mantle
#

Ahhh decorators for the registry

#

Ngl the way i wanted to do it is somehow have a global entry that you'd decorate functions, and params with

#

Also I'd like if the decorators would only override the register function once, esp if you add all 3 decorators

tardy willow
#

you mean a single decorator that could register all 3 types and would only override the register function once?

zinc mantle
#

iognore that one, thats more on me to do at some point if ever

tardy willow
#

im planning to use a weakmap to store their register type (chat input, context), options and registryOptions and check if it's last applied decorator and register them.

tardy willow
tardy willow
#

.

sacred shadow
#

@zinc mantle

sacred shadow
#

@zinc mantle I'm going to give you until saturday evening to review this otherwise I'm going to approve and merge it. This PR has been open for far too long already.