-
Notifications
You must be signed in to change notification settings - Fork 49
Open
Enhancement
Copy link
Labels
enhancementNew feature or requestNew feature or request
Description
Description
Current code for interacting with RLN smart contracts leaves too much room for errors between the Typescript code for interacting with the smart contracts and the smart contracts themselves.
User Story
As a developer, I want to have access to generated, strictly typed code using the relevant commit from the https://github.com/waku-org/waku-rlnv2-contract repo
I do NOT want to have to spend ANY time writing boilerplate code for reading from and interacting with smart contracts
I do NOT want to have to manually update ABIs or any other dependency when the smart contract code changes
Proposed Solution / Feature Design
- always get latest ABIs from https://github.com/waku-org/waku-rlnv2-contract , do NOT track the files in this repo separately
- either add a forge plugin to the above repo or use a script/lib in our repo to generate the Typescript code from the ABI/Solidity
- add an npm script and perhaps build/ci step to generate the typings
- use the typings (with a provider if necessary) to handle smart contract interaction in the code
Optional: Diagram or Draft of Design
Notes
- This may be more relevant for the rln website, but given the fact that we now rely on a smart contract read in order to get data necessary for generating the proof, it's likely high ROI to implement this in the waku/rln package as well
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request
Type
Projects
Status
In Progress