-
Notifications
You must be signed in to change notification settings - Fork 355
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
ERC20Votes docs #962
ERC20Votes docs #962
Conversation
Co-authored-by: Andrew Fleming <[email protected]>
Co-authored-by: Andrew Fleming <[email protected]>
Co-authored-by: Andrew Fleming <[email protected]>
Co-authored-by: Andrew Fleming <[email protected]>
Co-authored-by: Andrew Fleming <[email protected]>
… into feat/snip-12
…eat/erc20-votes-component
…eat/erc20-votes-component
Co-authored-by: Andrew Fleming <[email protected]>
Co-authored-by: Andrew Fleming <[email protected]>
…airo-contracts into feat/erc20-votes-component
…eat/erc20-votes-component
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.
The docs are looking good, Eric! I left some comments and questions
src/utils.cairo
Outdated
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.
I get not documenting structs
because of the forthcoming native StorageArray
; however, I feel like we should at least mention that this code is temporary. I'm not sure where exactly. Thoughts? Let's also not forget to track this as an issue once we're merged
And math
should be stable enough to document, no?
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.
math
documented!
Regarding Checkpoint and Trace I don't think we need to document them, since they are not intended as part of the library public API, they are just helpers for the erc20votes extension. Maybe we can move them outside of the utilities folder.
Regarding StorageArray, I don't think is worth documenting it since we don't want to support it, but to remove it in favor of the native implementation. Not sure where to mention that StorageArray is a temporal solution either, I vote we leave it for a different issue as well.
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.
|
||
[.contract-item] | ||
[[ERC20VotesComponent-DelegateChanged]] | ||
==== `[.contract-item-name]#++DelegateChanged++#++([key] delegator: ContractAddress, [key] from_delegate: ContractAddress, [key] to_delegate: ContractAddress)++` [.item-kind]#event# |
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.
The [key]
is not visually appealing :( though I think this should be included. For the sake of consistency, how do you feel about making this a separate issue so we can tackle all of the APIs at once?
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.
I think we should prioritize showing which keys are indexed, but agree maybe is better for a different issue, since we are releasing next week.
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.
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.
Also, the readme code block needs ERC20HooksEmptyImpl
Co-authored-by: Andrew Fleming <[email protected]>
…contracts into feat/erc20-votes-docs
…eat/erc20-votes-docs
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.
Left a final two suggestions (it's really just one). Otherwise, I think this is good to go!
Co-authored-by: Andrew Fleming <[email protected]>
Co-authored-by: Andrew Fleming <[email protected]>
Partially fixes #815
PR Checklist