slackapi / node-slack-interactive-messages

Slack Buttons, Menus, and Dialogs made simpler for Node
MIT License
133 stars 41 forks source link

name or value matching constraints #13

Closed aoberoi closed 5 years ago

aoberoi commented 7 years ago

Description

This issue is to discuss the need for an API to add matchers using the name and value properties of interactive message payloads. Currently, the module only supports matching on callback_id, type, and whether or not its the result of an unfurl. If this is a feature you are interested in, please share how you'd use it.

What type of issue is this? (place an x in one of the [ ])

Requirements

gterras commented 7 years ago

I think it would make things a little bit easier. Right now working on decent sized buttons branches, most of the actions needing specific treatment are just a switch case on name or value with functions returning a replacement. Having the ability to match for it would have made me using more actions. In the end it's just convenience. By the way thank you for your work !

aoberoi commented 6 years ago

great, the next step would be to propose an API for this type of matching. i'm open to suggestions.

shaydewael commented 5 years ago

Name and value aren't reliable matching criterion for Block Kit messages. We may be able to rethink how something similar might look in a Block Kit world if there's still interest.