In the visualizer you can extend the "types" defined by javascript with other specific types.
The structure of a value will be something like:
{"type":"mf", "value":"C10H20O3"}
Each type may be associated to a renderer. This could be a simple render allowing to put in a molecular formula the number in subscript or more complex renderer allowing to display a chart.
Please note that you may either enter the value or a URL where from where the value can be fetch