Skip to content

Add observable wrapper for meteor data subscriptions as addition to meteor-data-mixin #25

Closed
@istarkov

Description

@istarkov

In new react apps ES6-ES7 javascript syntax become very popular. But there are no mixins for react components created as ES6 classes.
It looks like it's not a big deal to create observable wrapper for Meteor subscriptions (using RxJs contract or any other) and use it as like as any other observable.
Since that your meteor-data-mixin get's more easy code, and users can use this observable to create HoC components and decorators as like as this https://gist.github.com/tgriesser/d5d80ade6f895c28e659

For example this code line https://github.com/meteor/react-packages/blob/master/packages/react-meteor-data/meteor-data-mixin.jsx#L20 is not a good solution (props can be freezed using 'Object.freeze' in any version of react), and this code can easily be avoided by using normal observable subscriptions.

There are a lot of additional usage behaviors if Observable subscriptions will be created. Like as subscription caching, counting etc...

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions