-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add new transaction of Mint type #604
Conversation
Coverage report
Show files with reduced coverage 🔻
Test suite run success549 tests passing in 49 suites. Report generated by 🧪jest coverage report action from 38ecb79 |
@@ -291,7 +294,62 @@ export class TransactionCreateCoder extends Coder<TransactionCreate, Transaction | |||
} | |||
} | |||
|
|||
export type Transaction = TransactionScript | TransactionCreate; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you elaborate on why this was removed? I think we can do TransactionScript | TransactionCreate | TransactionMint
, but I may be missing something
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it wasn't removed, it's just ahead in the code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TransactionScript | TransactionCreate | TransactionMint
was the initial idea, but then it breaks a lot of things and significantly makes transaction response usage worst because of small number of common properties.
then I did a refactor on typing stuff for Transaction
which now(optionally) accepts a generic informing transaction type
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@QuinnLee you can check the changed tests/files to understand better how it's working now
Add new Mint transaction
Transaction
will have all possible parameters as optional.Transaction<TransactionType.Script>
will have the exact params for Script transaction onlyTransaction<TransactionType.Create>
will have the exact params for Create transaction onlyTransaction<TransactionType.Mint>
will have the exact params for Mint transaction onlyCloses #603
Closes #602