Press n or j to go to the next uncovered block, b, p or k for the previous block.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | 3x 3x 3x 3x 3x 3x 1x 3x 1x | import { Cardano } from '@cardano-sdk/core'; export const createTxInput = (() => { let defaultIndex = 0; return ( txId = Cardano.TransactionId('6804edf9712d2b619edb6ac86861fe93a730693183a262b165fcc1ba1bc99cad'), address = Cardano.PaymentAddress('addr1vy36kffjf87vzkuyqc5g0ys3fe3pez5zvqg9r5z9q9kfrkg2cs093'), index = defaultIndex++ ) => ({ address, index, txId }); })(); export const createUnspentTxOutput = ( value: Cardano.Value, address = Cardano.PaymentAddress('addr1vy36kffjf87vzkuyqc5g0ys3fe3pez5zvqg9r5z9q9kfrkg2cs093') ): Cardano.Utxo => [createTxInput(), { address, value }]; export const createOutput = ( value: Cardano.Value, address = Cardano.PaymentAddress('addr1vyeljkh3vr4h9s3lyxe7g2meushk3m4nwyzdgtlg96e6mrgg8fnle') ): Cardano.TxOut => ({ address, value }); |