-
Notifications
You must be signed in to change notification settings - Fork 722
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
feat: Web3Wallet SDK #1771
feat: Web3Wallet SDK #1771
Conversation
…Session, respondSessionRequest & disconnectSession
…onProposals & getPendingSessionRequests
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.
This is shaping up really nicely 👍 Left few comments and one overall here: Do we need to manually re-declare some of the types inside new client and engine type files here? Or is it possible to re-assign these to already existing types from sign and auth sdks, thus keeping the in one place when we need to change them.
Similarly, some logic i.e catching errors and logging them is already done in those sdk's, so perhaps we don't need to repeat it here?
}; | ||
|
||
public getPendingSessionRequests: IWeb3WalletEngine["getPendingSessionRequests"] = () => { | ||
return this.client.pendingRequest.getAll(); |
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.
Not an item for now, but I think it would be interesting to discuss if this (pendingRequest
store) should be a proper part of SignClient, rather than layering it on top here, so we have first class support for pending session requests in the client itself.
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.
Great work on this Gancho 💯 🚀
My only real concern is how the treat pendingRequests
in the mid-long term, since we seem to be layering sign-specific persistence/logic on top of the actual sign client here.
I think it's fine for now and we should be able to easily switch over to a signClient-level implementation if/when that ships, but definitely wondering if it makes more sense to make that a first-class citizen in SignClient itself.
Description
Web3Wallet
SDK to simplifySign
&Auth
usage.Interfaces: https://gist.github.com/pedrouid/4067a262550ffb80ea93ab21cedba2fb
How Has This Been Tested?
integration tests for each method
Due Dilligence