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
After the release of abitype 1.0.7 and viem 2.21.54, we are now ready to finally replace ethers by viem in the context of EIP712.
Ideally we want to keep compatibility with users (like veworld) in this sense. This means that we should implement a mechanism to find out the primaryType from the types so users do not need to provide that value. This is how ethers does it. The reason because viem does not do it is because primaryType is part of the spec, and their ethos is to be as close as possible to it.
The steps to complete this ticket should be:
Revert this commit so a revert branch is created (we will modify it in the next steps, but the vast majority of the code should remain the same).
Implement the code to infer the primaryType from the types (see link above as a reference).
This means that method signature wise, our SDK should remain pretty much the same so there is no disruption for users when releasing the new version containing this.
(OPTIONAL but recommended) Build the packages locally and use them in veworld-mobile to validate that the changes are correct before creating the PR. By running yarn test in that repo should be enough for the validation.
The text was updated successfully, but these errors were encountered:
Summary
After the release of
abitype
1.0.7 andviem
2.21.54, we are now ready to finally replaceethers
byviem
in the context of EIP712.Ideally we want to keep compatibility with users (like
veworld
) in this sense. This means that we should implement a mechanism to find out theprimaryType
from thetypes
so users do not need to provide that value. This is howethers
does it. The reason becauseviem
does not do it is becauseprimaryType
is part of the spec, and their ethos is to be as close as possible to it.The steps to complete this ticket should be:
revert
branch is created (we will modify it in the next steps, but the vast majority of the code should remain the same).primaryType
from thetypes
(see link above as a reference).domain
'schainId
the VeChain values (see which ones are in this comment), both asstring
andbigint
.veworld-mobile
to validate that the changes are correct before creating the PR. By runningyarn test
in that repo should be enough for the validation.The text was updated successfully, but these errors were encountered: