As discussed in the previous talks here and here, we are working on extracting the bahmni-appointments UI as a separate app. Along with this, we are working on making it compatible with OpenMRS as well
The appointment module uses a lot of constants (e.g.
bahmniConfigURL), which are hardcoded as of now. We want to enable the app to be able to dynamically load these constants since a lot of these will be different when we run it on OpenMRS(Without Bahmni).
- Before the app loads, fetch constants as a JSON file(
- Store this JSON as part of
- Use the
Key:Valueinstead of Constants.
- We could use the JSON from
local storageas a cache for subsequent page loads.
We wanted to know, in which situations above two
localStorage items are present. If this is never the case, do we want to continue it keeping in this way? That would mean we won’t be able to use the
JSON directly since we cannot define
JSON values conditionally. We will need to do some preprocessing of
Let us know your comments/suggestions.