-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
feat: allow use of Observables on subscriptions with generic-sdk #4204
feat: allow use of Observables on subscriptions with generic-sdk #4204
Conversation
it's still not clear for me how to extend the Requester type. I'm thinking in adding an optional subscribe method to it and the invoke would be something like
instead of
or
|
…se<R> | Observable<R>
@dotansimha WDYT? |
This is a great idea! Thank you for implementing this, @onhate ! |
hi @dotansimha and @ardatan, did you have the chance to review this PR? |
guys, any chance we could move this PR this week? @dotansimha @ardatan |
@dotansimha @ardatan are you there? |
@onhate Thanks for the PR! LGTM! |
Great implementation @onhate ! I was looking for some solution like that. |
Thanks @onhate , it looks good. Thank you :) |
@dotansimha done! |
@dotansimha, @ardatan is there any plan to make this available on npm soon? |
The latest changes of this PR are available as alpha in npm: Quickly update your package.json by running:
|
Allow the use of Observables on subscription operations for Generic SDK
Generates a method that returns an Observable instead of a Promise.
When this config is enabled, the Requester response will change to this:
This is an optional configuration that does not breaks existing setup.