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: apply modular approach to fungible example contract #401

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ndkazu
Copy link

@ndkazu ndkazu commented Dec 8, 2024

Description

Issue #303
Simplify the contract code by using a modular design, similar to what is shown here: https://github.com/Cardinal-Cryptography/PSP22/blob/38e0b72ab165dc13cd420d9918dff7ae8c931021/lib.rs#L3-L7

Method

Create a trait Api in a different file traits.rs with all the function calls using api:: in lib.rs

@ndkazu ndkazu marked this pull request as draft December 8, 2024 16:56
@ndkazu
Copy link
Author

ndkazu commented Dec 8, 2024

Work in progress. First commit is already implementing the method described in some parts.

@chungquantin
Copy link
Collaborator

chungquantin commented Dec 9, 2024

Hi @ndkazu, thanks for making progress on this. I would say creating another example fungile-modular in the same folder is better. But let's keep the changes made to the fungible example for the code review purpose and refactor after it is approved.

@chungquantin chungquantin changed the title apply modular approach to fungible example contract chore: apply modular approach to fungible example contract Dec 9, 2024
@chungquantin
Copy link
Collaborator

chungquantin commented Dec 9, 2024

Discussed with the team and we decided that the issue for modular approach is no longer needed. My suggestion if you are still interested to contribute is to craft a few examples for the PSP22 contract: #337 . Let me know if you need any help!

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.

2 participants