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

[docs]: Replace deprecated subscribe() methods in documentation #5339

Closed
1 of 6 tasks
jakovljevic-mladen opened this issue Mar 4, 2020 · 0 comments · Fixed by #5352
Closed
1 of 6 tasks

[docs]: Replace deprecated subscribe() methods in documentation #5339

jakovljevic-mladen opened this issue Mar 4, 2020 · 0 comments · Fixed by #5352

Comments

@jakovljevic-mladen
Copy link
Member

Documentation Related To Component:

Observable

Please check those that apply

  • typo
  • documentation doesn't exist
  • documentation needs clarification
  • error(s) in example
  • needs example
  • needs update

Description Of The Issue

Observable's subscribe() method has some examples how to pass parameters, but there are some issues there:

  • Subscribe with an Observer example is probably fine.
  • Subscribe with functions uses deprecated subscribe method. Should a deprecated example be in the docs? It's OK to show users all (or many) possible ways to subscribe, but I think that deprecated methods should be noted or that examples with deprecated methods should not be used. This example (of summing 1, 2 and 3) is probably bad since it waits for complete event and having complete handler is not deprecated only if used with observer. I'd suggest changing an example (only to use next handler), but I'd add a note that adding other handlers should be probably done by passing an observer object. Is that OK?
  • Cancel a subscription example should use observer as parameter with no error handler at all.
@jakovljevic-mladen jakovljevic-mladen changed the title Replace deprecated subscribe() methods in documentation [docs] Replace deprecated subscribe() methods in documentation Mar 4, 2020
@jakovljevic-mladen jakovljevic-mladen changed the title [docs] Replace deprecated subscribe() methods in documentation [docs]: Replace deprecated subscribe() methods in documentation Mar 4, 2020
jakovljevic-mladen added a commit to jakovljevic-mladen/rxjs that referenced this issue Mar 11, 2020
* docs(subscribe): add comma after "In particular"

* docs(subscribe): add notice about asynchronously thrown errors

* docs(subscribe): add notice about deprecated usages of `subscribe` method (relates to ReactiveX#4159)

* docs(subscribe): add notice about using `subscribe` with no params

* docs(subscribe): fix example not to use deprecated `subscribe`

* docs(subscribe): add example with deprecated `subscribe` with notice that it's deprecated

* docs(subscribe): fix unsubscribe example replacing deprecated `subscribe` usage with Observer

* docs(subscribe): add notice that unprovided error handlers will cause throwing errors asynchronously

* docs(subscribe): fix return type

Closes ReactiveX#5339
cartant pushed a commit to jakovljevic-mladen/rxjs that referenced this issue Mar 19, 2021
* docs(subscribe): add comma after "In particular"

* docs(subscribe): add notice about asynchronously thrown errors

* docs(subscribe): add notice about deprecated usages of `subscribe` method (relates to ReactiveX#4159)

* docs(subscribe): add notice about using `subscribe` with no params

* docs(subscribe): fix example not to use deprecated `subscribe`

* docs(subscribe): add example with deprecated `subscribe` with notice that it's deprecated

* docs(subscribe): fix unsubscribe example replacing deprecated `subscribe` usage with Observer

* docs(subscribe): add notice that unprovided error handlers will cause throwing errors asynchronously

* docs(subscribe): fix return type

Closes ReactiveX#5339
cartant added a commit that referenced this issue Mar 19, 2021
* docs(subscribe): update `subscribe` documentation

* docs(subscribe): add comma after "In particular"

* docs(subscribe): add notice about asynchronously thrown errors

* docs(subscribe): add notice about deprecated usages of `subscribe` method (relates to #4159)

* docs(subscribe): add notice about using `subscribe` with no params

* docs(subscribe): fix example not to use deprecated `subscribe`

* docs(subscribe): add example with deprecated `subscribe` with notice that it's deprecated

* docs(subscribe): fix unsubscribe example replacing deprecated `subscribe` usage with Observer

* docs(subscribe): add notice that unprovided error handlers will cause throwing errors asynchronously

* docs(subscribe): fix return type

Closes #5339

* docs: minor grammar tweaks

And remove specific mention of deprecations. Let the signature
deprecations to the talking.

* docs: more minor tweaks

Co-authored-by: Nicholas Jamieson <[email protected]>
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

Successfully merging a pull request may close this issue.

1 participant