Data4ALL
Data4ALL copied to clipboard
Suggesting Rewrite to how Datasets are Populated
I think it may be easier to maintain if there was one large DatasetDictionary js object that included information for every dataset {name, id, download, classification, pathname} and then were looped and populated into html elements.
Something like:
I saw that you have some outstanding PR's that update the UI so there could be some conflicts with a change this big but it would greatly clean up you index.html file and allow for easier dataset edits
Let me know what you think - I already started the work on this if you are interested in moving to this functionality.
i wanted to keep it simple ,for people contributing for the first time also. they could drop in a dataset by copying above code and changing id in few lines.
I think this suggested workflow to add datasets would be pretty simple.
All the person would need to do is:
- add the raw dataset
- make a new dataset item in the dataset object with all those standard keys {name, id, pathname, etc}.
This allows you to easily make edits to the html structure if you ever needed to, since it is simply looping over this dataset and plugging in values for each dataset.
I can send over the PR soon to show you how it could work and if you're not interested I can close this issue
yup send a PR. tq