UNPKG
@ensdomains/unruggable-gateways
Version:
bold-unfinalized (0.0.0-bold-unfinalized.3)
latest (0.0.2)
scroll-new (0.0.0-scroll-new.0)
0.0.2
0.0.1
0.0.0-scroll-new.0
0.0.0-bold-unfinalized.3
0.0.0-bold-unfinalized.2
0.0.0-bold-unfinalized.0
Trustless Ethereum Multichain CCIP-Read Gateway
@ensdomains/unruggable-gateways
/
dist
/
esm
/
eth
/
types.mjs
8 lines
(7 loc)
•
277 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
import
{
ABI_CODER
,
NULL_CODE_HASH
}
from
'../utils.mjs'
;
export
function
isContract
(
proof
) {
return
(proof.
codeHash
!==
NULL_CODE_HASH
&& proof.
keccakCodeHash
!==
NULL_CODE_HASH
); }
export
function
encodeProof
(
proof
) {
return
ABI_CODER
.
encode
([
'bytes[]'
], [proof]); }