peopledoc / OPE

One Page for Equity
3 stars 0 forks source link

Make detail page dynamic #25

Open nadege opened 4 years ago

nadege commented 4 years ago

It would be great if we could use the same data-detail.html file for each indicator instead of having to duplicate the html. For now we have only one so problem is not obvious.

What could be done ? Use a query parameter to know which indicator is to be displayed: data-detail.html?indicator=gender_distribution

Then depending of the parameter value, we could know which indicator to display, so which JS functions to call to display the right chart, title and law text.