Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: rename
encodeAbi
& decodeAbi
+ add inferred return type…
…s to `decodeAbiParameters` (#85) * feat: rename encodeAbi/decodeAbi to encodeAbiParameters/decodeAbiParameters; refactor abi decode return type * chore: changeset * lint * chore: update abitype * fix * fix * fix * docs: add getAbiItem * docs: update
- Loading branch information
Showing
54 changed files
with
2,668 additions
and
2,278 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
"viem": patch | ||
--- | ||
|
||
**Breaking:** Renamed `encodeAbi` & `decodeAbi` to `encodeAbiParameters` & `decodeAbiParameters`, and modified API from named arguments to inplace arguments: | ||
|
||
```diff | ||
import { | ||
- encodeAbi, | ||
- decodeAbi, | ||
+ encodeAbiParameters, | ||
+ decodeAbiParameters, | ||
} from 'viem' | ||
|
||
-const result = encodeAbi({ params, values }) | ||
+const result = encodeAbiParameters(params, values) | ||
|
||
-const result = decodeAbi({ params, data }) | ||
+const result = decodeAbiParameters(params, data) | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,6 +21,7 @@ bench | |
# @wagmi/cli | ||
generated.ts | ||
|
||
abi/** | ||
chains/** | ||
contract/** | ||
ens/** | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
2350d1a
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
viem-site – ./site
viem-site.vercel.app
viem.sh
www.viem.sh
viem-site-git-main-wagmi-dev.vercel.app
viem-site-wagmi-dev.vercel.app
2350d1a
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
viem-playground – ./playgrounds/browser
viem-playground.vercel.app
viem-playground-wagmi-dev.vercel.app
viem-playground-git-main-wagmi-dev.vercel.app