Let me present a simple use case to ask my question. @andu033 is integrating Attachments widgets into React Components as part of GSoC 2019. When coming to the thumbnail component we need to know in which format to display the date-time stamp. Attachments (the module) has been providing this to its framing GSP pages through a config passed on from the controller (here and here). This was simple because everything was “attachments”.
Now in React Components, I understand that we want components to be standalone, however they might need to share configs for the sake of UI consistency. Such as how to format dates for instance.
I saw this
How do we avoid this for instance? Should the store maintain an expandable configuration, or what would be your take on this?
Thanks @mogoodrich, yes it’s rather the latter about this:
Default date format from the store
This suggests that the store would be pre-filled with defaults, and those have to be managed somewhere. It doesn’t have to come from the backend though, there could be some sort of front-end config for that (a bit like Bahmni Apps is being configured).