docs: Privy wallet integration details in contracts SDK documentation#9
docs: Privy wallet integration details in contracts SDK documentation#9
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5804413bb8
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| } from '@oaknetwork/contracts'; | ||
| import { useWallets } from '@privy-io/react-auth'; | ||
|
|
||
| const { wallets } = useWallets(); |
There was a problem hiding this comment.
Wrap useWallets call in a React component
This example calls useWallets() at module scope, but React hooks are only valid inside a function component or another custom hook. In the quickstart context, users are likely to paste this into a plain script/module and hit an "Invalid hook call" runtime error before the SDK client is created. Please show this inside a React component (or use a non-hook Privy API) so the snippet is runnable as written.
Useful? React with 👍 / 👎.
…k/contracts-sdk' across multiple documentation files
Summary
@privy-io/react-authwallets tocreateOakContractsClientusing viem'scustom()transport