recompose icon indicating copy to clipboard operation
recompose copied to clipboard

Update rxjsObservableConfig for rxjs 6

Open wuct opened this issue 8 years ago • 4 comments

Need some discussion before merging:

  1. There were rxjs4ObservableConfig.js and rxjsObservableConfig.js (for rxjs 5) before. This PR upgrade rxjsObservableConfig.js directly to adopt rxjs 6, but it's a breaking change. We might want to create separate files for both rxjs 5 and rxjs 6.

  2. Rxjs used to polyfill Symbol.observable, but it has been removed since https://github.com/ReactiveX/rxjs/pull/3387. We might need to add a notice about polyfill Symbol.observable to the doc.

wuct avatar May 01 '18 17:05 wuct

What are u think to split library on 2, ie recompose and recompose-rx(-observable, -blabla) and move all the streaming parts out of the recompose library.

Also I think we can move on https://github.com/facebook/react/tree/master/packages/create-subscription to support async in the future

istarkov avatar May 01 '18 17:05 istarkov

It would be a good idea to separate them. But I'm thinking about keeping the es-observable parts remain in Recompose and move only those 3rd-party-config files into other libraries. The reason for me to separate them is to have better version controlling.

And yes, I think we need to introduce create-subscription to handle streaming events.

wuct avatar May 05 '18 04:05 wuct

RxJS 6 has been out for awhile now. Is this PR good to merge? Re. the suggestion of moving 3rd-party-config files into other libraries, perhaps keep that idea to a separate PR, so we can unblock this one?

OliverJAsh avatar Aug 14 '18 12:08 OliverJAsh

For those people waiting for this PR, there is a simple configuration possible to get recompose working with RxJS@^6.0.0:

import { from } from 'rxjs';

setObservableConfig({
  fromESObservable: from,
});

elmarburke avatar Sep 14 '18 09:09 elmarburke