Skip to content

cleanup method names and update cca examples #48

@pyramation

Description

@pyramation

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

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions