WatermelonDB icon indicating copy to clipboard operation
WatermelonDB copied to clipboard

Add support to observe on selected columns of a collection

Open pranjal-jain opened this issue 5 years ago • 7 comments

Solves https://github.com/Nozbe/WatermelonDB/issues/217

  • [x] a Changelog entry
  • [x] describe the feature briefly in the appropriate document in docs-master/ so that others can find this feature
  • [x] name the method(s) experimentalObserveColumns and Q.experimentalSelect
  • [x] add test for the column-only observation function.

pranjal-jain avatar Jan 20 '20 09:01 pranjal-jain

I know it's WIP, but a few things will be required:

  • a Changelog entry
  • describe the feature briefly in the appropriate document in docs-master/ so that others can find this feature
  • please name the method(s) experimentalObserveColumns and Q.experimentalSelect -- the reason is that I'm not yet sure if this is the right API to express those features, and so I want to be able to rename this/change slightly later.
  • add test for the column-only observation function. You can take a look at other observer tests for inspiration

Thanks so much for contributing @pranjal-jain!

radex avatar Jan 20 '20 13:01 radex

@radex Thanks for taking out time to review this. I have made the changes requested by you.

I have exposed experimentalObserveColumns(['col1', 'col2']) and experimentalFetchColumns(['col1', 'col2']) on Query.

Let me know if you have a better API in mind to expose this feature.

pranjal-jain avatar Jan 30 '20 12:01 pranjal-jain

amazing @pranjal-jain! Thanks for doing this work! I will try to check out the PR in the next week or so

radex avatar Jan 30 '20 12:01 radex

@radex Waiting for you to review this whenever you get time.

pranjal-jain avatar Feb 24 '20 18:02 pranjal-jain

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

stale[bot] avatar Aug 23 '20 14:08 stale[bot]

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

stale[bot] avatar Jun 16 '21 23:06 stale[bot]

@pranjal-jain @radex I have merged these changes into latest master here pranjal-jain#4. With latest master merged, here's the updated diff with nozbe/master

zhirzh avatar Nov 10 '21 18:11 zhirzh