crosstalk icon indicating copy to clipboard operation
crosstalk copied to clipboard

provide index/list of groups

Open timelyportfolio opened this issue 8 years ago • 3 comments

There seems to be no way to explore available groups in crosstalk. Is this by design, and if so what are the reasons? Ideally, it seems like there should be a public method to provide a list of groups available, so that we can subscribe in JavaScript. Otherwise, we only know groups through the SharedData instance in R.

timelyportfolio avatar Nov 08 '16 18:11 timelyportfolio

I'm staying conservative with the API because it's very unclear to me what direction crosstalk will go in next. The more I open up the APIs, the more things get set in stone (part of the reason why I moved away from having people directly interact with groups and vars).

What is it you'd like to do?

jcheng5 avatar Dec 14 '16 22:12 jcheng5

Without knowledge of the SharedData in R, it is very difficult to know to which group an htmlwidget or other component belongs. In most cases, we could derive this from inspection of the htmlwidget instance or data, but unfortunately implementation is not guaranteed to be consistent. If someone wanted to add behavior in JavaScript ex-post or without direct specification of the group in SharedData, it can be nearly impossible to subscribe to the crosstalk events.

I understand what you are saying about an unstable API and care in exposing the minimum, but some lookup mechanism would be very valuable.

timelyportfolio avatar Dec 15 '16 01:12 timelyportfolio

any thoughts on this? I keep getting blocked by this unfortunately. Happy to try a pull request.

timelyportfolio avatar Dec 17 '17 19:12 timelyportfolio