Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: refactor getAction #2429

Merged
merged 2 commits into from
Jun 20, 2024
Merged

chore: refactor getAction #2429

merged 2 commits into from
Jun 20, 2024

Conversation

jxom
Copy link
Member

@jxom jxom commented Jun 20, 2024

supersedes #2404


PR-Codex overview

This PR focuses on fixing an issue where getAction would ignore nullish return values.

Detailed summary

  • Added type imports for PublicActions, WalletActions, Transport, Account, Chain, and RpcSchema
  • Refactored getAction function to accept a more generic client type and handle minified function names
  • Updated test to cover nullish return values from synchronous Client Actions

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Copy link

vercel bot commented Jun 20, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
viem ✅ Ready (Inspect) Visit Preview Jun 20, 2024 9:30pm

Copy link

changeset-bot bot commented Jun 20, 2024

🦋 Changeset detected

Latest commit: 78aecc8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
viem Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@jxom jxom merged commit 3781bbb into main Jun 20, 2024
2 of 3 checks passed
@jxom jxom deleted the jxom/getAction branch June 20, 2024 21:03
@github-actions github-actions bot mentioned this pull request Jun 20, 2024
Copy link
Contributor

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
viem (esm) 59.02 KB (0%) 1.2 s (0%) 1.3 s (+21.02% 🔺) 2.5 s
viem (cjs) 70.14 KB (0%) 1.5 s (0%) 1.5 s (+5.23% 🔺) 2.9 s
viem (minimal surface - tree-shaking) 6.1 KB (0%) 122 ms (0%) 69 ms (-55.79% 🔽) 191 ms
viem/accounts 73.87 KB (0%) 1.5 s (0%) 471 ms (+23.91% 🔺) 2 s
viem/accounts (tree-shaking) 18.94 KB (0%) 379 ms (0%) 284 ms (+172.87% 🔺) 663 ms
viem/actions 45.28 KB (0%) 906 ms (0%) 457 ms (-16.33% 🔽) 1.4 s
viem/actions (tree-shaking) 318 B (0%) 10 ms (0%) 5 ms (-43.39% 🔽) 15 ms
viem/chains 28.65 KB (0%) 574 ms (0%) 660 ms (-36.08% 🔽) 1.3 s
viem/chains (tree-shaking) 324 B (0%) 10 ms (0%) 5 ms (+36.32% 🔺) 15 ms
viem/chains/utils 1.02 KB (0%) 21 ms (0%) 8 ms (+50.98% 🔺) 29 ms
viem/ens 45.28 KB (0%) 906 ms (0%) 419 ms (-24.06% 🔽) 1.4 s
viem/ens (tree-shaking) 22 KB (0%) 440 ms (0%) 437 ms (-0.19% 🔽) 877 ms
viem/siwe 29.97 KB (0%) 600 ms (0%) 493 ms (+56.56% 🔺) 1.1 s
viem/siwe (tree-shaking) 28.81 KB (0%) 577 ms (0%) 748 ms (+100.01% 🔺) 1.4 s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant