A single member of an EIP-712 struct type.
A field pairs a member name with its Solidity type string (e.g. "string",
"address", "uint256", "Person", "Person[]"). The ordered list of fields for a
given struct type is what encodeType/hashStruct operate on in the EIP-712 algorithm.
Both name and type are plain strings using the JSON/Solidity spelling (for example the
domain's chain id field is named "chainId" with type "uint256").
Summary
Functions
Creates a new Ethers.TypedData.Field from a map, keyword list, or an existing field.
Types
Functions
Creates a new Ethers.TypedData.Field from a map, keyword list, or an existing field.
Accepts atom (:name/:type) or string ("name"/"type") keys. An existing
Ethers.TypedData.Field is returned unchanged.
Examples
iex> Ethers.TypedData.Field.new(%{name: "wallet", type: "address"})
%Ethers.TypedData.Field{name: "wallet", type: "address"}
iex> Ethers.TypedData.Field.new(%{"name" => "contents", "type" => "string"})
%Ethers.TypedData.Field{name: "contents", type: "string"}