feat: Default payloads
- Dominant language
- TypeScript
- Stars
- 35
- Forks
- 14
- Avg merge
- 6h 39m
- Merged PRs (30d)
- 2
Description
It's a common thing to create menu ranges where all buttons have the same payload object.
It would be useful if one could do
```ts
const range = new MenuRange({ payload: 'default-payload' })
```
which would then be set as the default value for all buttons on that range. Hence, it is sufficient to pass a string to `range.text` instead of always having to specify the same payload.
It needs yet to be decided whether or not the default payload should be passed on the menu ranges created for dynamic ranges inside `range`, but it's likely this this is not a good idea.
Contributor guide
No contributing guide indexed for this repository
Research direction
Locate the MenuRange implementation and the handling of range.text, then inspect any related tests or examples. Define how a range-level payload should apply when text is given without an explicit payload, including whether dynamic ranges inherit it; done means the behavior is covered by tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100