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

cleanup method names and update cca examples #48

Open
pyramation opened this issue Oct 3, 2023 · 0 comments
Open

cleanup method names and update cca examples #48

pyramation opened this issue Oct 3, 2023 · 0 comments
Assignees

Comments

@pyramation
Copy link
Contributor

Asset (for ATOM):
base: uatom
display: atom
symbol: ATOM

Symbol is best for user facing and when you need simplicity.
Base is good for being the only one guaranteed to be unique per chain.
The word ‘Display’ I would avoid entirely for these functions.
And Denom is a bit ambiguous, but is the terminology I see being used on-chain.
Since we’re just starting to see symbol collisions, I guess Id recommend Denom or Symbol, but also allow for chain name just to avoid ambiguity.
So getPriceByDenom(uatom, cosmoshub) or getPriceByDenom(uatom) would work.
And getPriceBySymbol(ATOM) would work and getPriceBySymbol(NOM,onomy) would also work, but getPriceBySymbol(NOM) would fail (or return an array or something) due to the two possibilities.

cc @HebeHe1986

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

3 participants