You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/docs/compiler/script-limits.md
+6-16Lines changed: 6 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -78,18 +78,8 @@ Before CashTokens `546` bytes was often used as good default value, however with
78
78
For ease of development, it is standard practice to use 1,000 satoshis as dust to outputs.
79
79
80
80
:::note
81
-
The standard practice of 1,000 satoshis as dust amount for outputs is only considering `P2PH`, `P2SH` and `P2PK` output types.
82
-
For `P2MS` (raw multisig) a higher dust limits may be required, you can [find more info here][info-dust-limit]
83
-
:::
84
-
85
-
### Output Standardness
86
-
87
-
Bitcoin Cash only allows a few types of `lockingBytecode` scripts for outputs in the normal network relay rules. These are called 'standard outputs', contrasted to 'non-standard outputs' which cause the transaction not to relay on the network.
88
-
89
-
There's 4 types of standard output types: `P2PKH`, `P2SH` (which includes `P2SH20` & `P2SH32`), `P2MS` and `OP_RETURN` data-outputs. For more details see the [standard outputs documentation][standard-outputs-docs].
90
-
91
-
:::caution
92
-
The `lockingBytecode` standardness rules can be important for smart contract developers, and is why CashScript has helpers like `LockingBytecodeP2PKH`, `LockingBytecodeP2SH32` and `LockingBytecodeNullData`.
81
+
The standard practice of 1,000 satoshis as dust amount for outputs is only considering `P2PKH`, `P2SH20` and `P2SH32` output types.
82
+
For other custom locking bytecode outputs a higher dust limits may be required, you can [find more info here][info-dust-limit]
93
83
:::
94
84
95
85
### Minimum Relay Fee
@@ -100,15 +90,15 @@ The Bitcoin Cash protocol does not strictly enforce minimum fees for transaction
100
90
101
91
| Limit type | Constraint |
102
92
|------------|-------------|
103
-
| Max contract size |1,650 bytes (standardness) |
104
-
| NFT commitment length |40 bytes (consensus) |
93
+
| Max contract size |10,000 bytes (consensus) |
94
+
| NFT commitment length |128 bytes (consensus) |
105
95
| Operation cost limit | Based on script length (consensus) |
106
96
| Max stack element size | 10,000 bytes (consensus) |
107
97
| Max transaction size | 100,000 bytes for standardness (1MB for consensus) |
108
-
| Max OP_RETURN data size | 220 bytes data payload (standardness) |
Copy file name to clipboardExpand all lines: website/docs/sdk/transaction-builder.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -113,7 +113,7 @@ transactionBuilder.addOutput(output: Output): this
113
113
transactionBuilder.addOutputs(outputs: Output[]): this
114
114
```
115
115
116
-
Adds a single output or a list of outputs to the transaction.
116
+
Adds a single output or a list of outputs to the transaction. The `to` field in an output can be a string representing a cash address, or a `Uint8Array` representing a locking bytecode. For `P2PKH`, `P2SH20` and `P2SH32` outputs, it is easiest to use the cash address string. For `P2S` outputs, you need to use the locking bytecode.
0 commit comments