diff --git a/zip-0320.html b/zip-0320.html index 45ebcb4f..31d4d82b 100644 --- a/zip-0320.html +++ b/zip-0320.html @@ -73,9 +73,10 @@ Pull-Request: <https://githu

Wallets and other Senders sending to a TEX address MUST ensure that only transparent UTXOs are spent in the creation of a transaction.

Reference Implementation (Alternative 1)

- +console.log(t1)

Alternative 2

@@ -134,28 +136,30 @@ A Unified Viewing Key MUST contain at least one shielded Item (Typecodes

Wallets and other Senders sending to a Traceable Unified Address MUST ensure that only transparent UTXOs are spent in the creation of a transaction.

Reference Implementation (Alternative 2)

-

Javascript library zcash_address_wasm 13:

- +});

Rust:

- +}

Analysis of Alternative 1

diff --git a/zip-0320.rst b/zip-0320.rst index d81e8e47..9a5c87b7 100644 --- a/zip-0320.rst +++ b/zip-0320.rst @@ -130,7 +130,7 @@ transparent UTXOs are spent in the creation of a transaction. Reference Implementation (Alternative 1) ---------------------------------------- -.. code-block: javascript +Javascript:: import bs58check from 'bs58check' import {bech32m} from 'bech32' @@ -234,11 +234,10 @@ that only transparent UTXOs are spent in the creation of a transaction. Reference Implementation (Alternative 2) ---------------------------------------- -Javascript library `zcash_address_wasm` [#zcash_address_wasm]_: +Javascript using `zcash_address_wasm` [#zcash_address_wasm]_:: -.. code-block: javascript - import init, { to_traceable_address } from 'zcash_address_wasm;; - init().then(() => { + import init, { to_traceable_address } from 'zcash_address_wasm'; + init().then(() => { var t_address = "t1VmmGiyjVNeCjxDZzg7vZmd99WyzVby9yC"; // Create a deposit address that is valid for 30 days @@ -248,11 +247,10 @@ Javascript library `zcash_address_wasm` [#zcash_address_wasm]_: var traceable_address = to_traceable_address(t_address, expiry_unix_seconds); console.log(traceable_address); - }); + }); -Rust: +Rust:: -.. code-block: rust use zcash_address::{ unified::{self, Encoding}, Network, ToAddress, TryFromAddress, ZcashAddress,