RadarTech / lnrpc

A Typescript gRPC client for LND with support for all LND sub-servers
MIT License
43 stars 13 forks source link

Typed subscribe stream event data #29

Closed wbobeirne closed 5 years ago

wbobeirne commented 5 years ago

It would be excellent of methods like subscribeInvoices or subscribeTransactions had typed data for their events. It looks like the default Readable class doesn't have a way of providing types for instances of it, so I'm not sure how this is done, but it'd certainly make working with these streams a lot easier.

cavanmflynn commented 5 years ago

Good idea. We can declare generic streams that will allow us to feed the stream types to the listeners.

cavanmflynn commented 5 years ago

Typed streams have been released in v0.5.2-beta.5.

wbobeirne commented 5 years ago

Y'all work fast, this is amazing. Thanks for the quick work!