The following functions are available globally.
Serializes a Flood object into a JSON string.
The object passed into this function can be either a
Double. The keys of the Dictionaries must be of type String. The values of the Arrays and Dictionaries must of type
func json(from value: String, prioritizedEntries: String) -> String
The object to serialize into a JSON sttring.prioritizedEntries
The list of dictionary keys which should appear above other dictionary keys in the outputed string. Entries appearing earlier in the list will appear earlier in the outputed string.
A string whose contents is the serialized JSON data.
Deserializes the contents of the JSON file at the specified path.
func loadJSON(_ path: String) -> Dictionary
The relative path to the JSON file within the template.
A dictionary containing the deserialized JSON data.