-
Notifications
You must be signed in to change notification settings - Fork 310
Open
Labels
featureBrand new functionality. New pages, workflows, endpoints, etc.Brand new functionality. New pages, workflows, endpoints, etc.
Description
Problem
Different transaction types often require dedicated code. However, even after checking the payload type, the payload needs to be kept in its own variable to preserve any type checks or assertions. There is no way to assert that a transaction has a given payload type
Solution
Introduce generics for transaction types. Something like
type StacksTransactionWire<TPayload = PayloadWire> = {
payload: TPayload
// ... other props
}This would allow typing a given transaction's payload (and possibly other internal structures) without having to keep them as separate variables.
Metadata
Metadata
Assignees
Labels
featureBrand new functionality. New pages, workflows, endpoints, etc.Brand new functionality. New pages, workflows, endpoints, etc.