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

feat: add config object to connectable #6267

Merged
merged 3 commits into from
Apr 27, 2021

Conversation

cartant
Copy link
Collaborator

@cartant cartant commented Apr 27, 2021

Description:

This PR changes the API of the new-to-version-7 connectable function. The changes introduce a config object (much like the one used in the connect and share operators) that:

  • allows a connector subject factory to be passed;
  • allows a resetOnDisconnect option to be specified.

Without these changes, it wasn't possible to refactor all use cases of ConnectableObservable to use connectable because ConnectableObservable would reset its subject upon disconnection - that is, on calling unsubscribe on the Subscription returned from the connect method.

This PR adds a few tests (there were none) for connectable.

Related issue (if exists): Nope

@benlesh benlesh merged commit 4d98b40 into ReactiveX:master Apr 27, 2021
@cartant cartant deleted the cartant/connectable branch May 2, 2021 04:59
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 this pull request may close these issues.

2 participants