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

interface: API crate(s) for token2022 #65

Open
joncinque opened this issue Jan 13, 2025 · 0 comments
Open

interface: API crate(s) for token2022 #65

joncinque opened this issue Jan 13, 2025 · 0 comments

Comments

@joncinque
Copy link
Contributor

Recreated from solana-labs/solana-program-library#6466

Currently if you want to build a token2022 instruction, parse an account etc, you import the whole program.

Problem 1: this forces you to compile the whole program and bring in dependencies that are only used in internal program code.
Problem 2: token2022 is a huge program with multiple responsibilities so we probably need multiple API crates. For example, only some users of token2022 would need to use anything involving the zk token sdk.

Solution:

Rip a bunch of code out of the program crate and into various API crates. Re-export in spl-token-2022 for backwards compatibility

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

No branches or pull requests

1 participant