serum-ts icon indicating copy to clipboard operation
serum-ts copied to clipboard

subscription utility onAccountChange for asks/bids?

Open etodanik opened this issue 3 years ago • 0 comments

I'd be happy to provide a PR for this, but first I want to know if there's interest. From what I see, the Dex UI ends up accessing the _decoded.asks and _decoded.bids and then set up a listener using connection.onAccountChange() on the public key of the ask/bid accounts.

  1. First of all, (and this might belong on the UI repo, but I think maybe some of the contributors here can be knowledgable on that particular choice), why access market._decoded.asks and not market. asksAddress? The latter seems cleaner.
  2. Would there be interest in a PR that adds the ability to onBidsChange and onAsksChange?

etodanik avatar May 25 '21 17:05 etodanik