Open
Description
If the following are true
- Settings are usually toggles, dropdowns, textfields, etc
- We need a JSON object structure to power search capabilities Feat/settings search #13214
- That JSON structure is relied upon in many places to make sure search capabilities work
- Adding a new setting in code requires touching many different files now to keep search working
- The current way of scrolling a section into view by registering refs with sections could potentially lead to memory leaks or at least make memory leaks harder to diagnose
- Settings page is among some of the oldest CSS currently maintained
It makes sense to me to refactor the settings page to use the template system such that a single JSON tree can be used to both render search and the settings under it. We could greatly reduce complexity of the current implementation as well as make adding new settings relatively painless. We would need to make sure that the settings page has UI components for things like toggles, textfields, etc, but this would make updating the look and feel of the settings page profoundly easier in the future.
I would say that we would simply have the contacts/address book and network tabs as exceptions to this rule given that they do not follow the pattern of being predominately individual toggles/fields