I need a stable and secure convertion algorithm (any language), that can produce the final output as "first class" JSON objects. Example:
jCard format:
[["version", {}, "text", "4.0"],["fn", {}, "text", "Forrest Gump"]]
First-class JSON format:
{"version":"4.0","fn":"Forrest Gump"}
.
In python first, I create one function named jcard_to_json that takes a jCard as input and converts it to a "first-class" JSON object. The function iterates over the items in the jCard, and for each item, it adds a key-value pair to the json_obj dictionary, where the key is the first item in the jCard thing and the value is the fourth item
Example:-