Document the transaction object with examples for onTransaction #832
Labels
snaps
Related to Snaps content.
team-snaps-platform
tech-writing
Requires updates to documentation content.
We have received feedback about the onTransaction export:
I was looking into a Snap that uses the "transaction" object returned by the "onTransaction" hook. The Snap accesses several properties of this object, but does not check if they are defined. Thus, I was wondering whether these properties were guaranteed to be defined by MM. I wasn't able to find any reference in the doc, but maybe I haven't looked in the right place.
To be clear, we do not document the transaction object and it isn't documented elsewhere. We should explain what to expect from it and provide examples. As far as I know, it differs depending on the type of transaction, and nothing is guaranteed to be there, but we should at least give examples.
The text was updated successfully, but these errors were encountered: