Closed rkralston closed 6 years ago
Found it. Posted answer on SO.
I added another answer:
Note that in addition to directly accessing the exported
selectors
andactions
, both are available through React Context as well, e.g. inLocalPlugin.components.TableBodyContainer
. Context should expose the "best"selectors
/actions
for the current<Griddle />
after plugins have been applied.Some work was started in https://github.com/GriddleGriddle/Griddle/pull/743 to make selectors more composable, but the PR has gone stale.
Glad to answer any questions as you embark upon creating your plugins.
Griddle version
^1.13.1
Expected Behavior
Create external plugin that can not only respond to actions, but can fire them.
Actual Behavior
Unknown at this time
Steps to reproduce
Try to build a plugin
Pull request with failing test or storybook story with issue
NA While this step is not necessary, a failing test(s) and/or a storybook story will help us resolve the issue much more easily. Please see the README for more information. https://stackoverflow.com/questions/51772957/have-a-good-griddle-react-plugin-example
I asked the question on SO. I'm reading through the code and will eventually get there on my own. However, my client is not really happy paying me to learn YANAT. Taking the LocalPlugin external would just about solve this for me. I am planning the following as plugins:
A Bootstrap implementation that is only dependent on styling, not components.
A Grouping display
A Pivot table display
A map (the existing example is good; however, it does not render correctly in full screen mode.)
An external data source plugin
The two plugins built internally are good examples of what is needed; however, they import a lot from the Griddle project - specifically the actions for firing those off. I'm experienced with JS, but new to React. What I need may be simple. I just haven't put it together yet. Examples would be greatly appreciated. OTW, I'll run out of time and have to build them inside Griddle - hardly desirable.
Thanks for any help. Love the project. Look forward to a long collaboration.