enable/disable typing indicator per message?
constantx opened this issue · comments
The middleware is working beautifully, though there's no option to control the typing indicator per message inside a conversation.
I think adding a flag per message, when using convo.say
, convo.addMessage
, and convo.askQuestion
would make it more flexible?
Proposal is adding a withTyping
to a message that can be read inside the middleware. What do you think @MarcL ? I can do a PR for this.
Hey @constantx.
Interesting idea but a question.
Why would you want the typing indicator on some messages and not others?
I feel like it should be enabled or not rather than some messages having it.
I guess it could work as an override, perhaps via the config?
My other worry is that you'd be altering the format of Botkit messages by adding a new property (unless withTyping
already exists in Botkit).
Thoughts?
I guess it could work as an override, perhaps via the config?
Yes, I'm proposing an override per message as needed :) We have a few cases where we want to send a series of message quickly one after another inside a convo (but separate message) to show the info quickly to users.
My other worry is that you'd be altering the format of Botkit messages by adding a new property (unless withTyping already exists in Botkit).
Can check for it inside the typing middleware, and delete it off the message before next()
?