For example:This structure is equivalent to the collections that you can find in classic document databases. Why are diamond shapes forming from these evenly-spaced lines? a value with in it would end the script tag. One way to store such metadata in data-* attributes is to create a separate data-* attribute for each piece of information you wish to store. Another thought that could be used is store the JSON data as a base64 string in the attribute and then using window.atob or window.btoa to restore it to usable JSON data. What was the name of this horror/science fiction story involving orcas/killer whales? What would you like to do? The JSON empty concept applies for arrays and objects as shown below. EDIT - Example solution using PHP and jQuery. The values in the arrays are separated by ‘,’ (comma). How to read Json array data using JsonArray? This is the concept of a black box. You should probable explain why and ask for different solution since I'm quite sure this isn't the best. JSON (JavaScript Object Notation, pronounced / ˈ dʒ eɪ s ən /; also / ˈ dʒ eɪ ˌ s ɒ n /) is an open standard file format, and data interchange format, that uses human-readable text to store and transmit data objects consisting of attribute–value pairs and array data types (or any other serializable value). Spatie's Data Transfer Object (DTO) package, that's what! Property Description Required; type: The type property of the copy activity source must be set to JSONSource. You can prob use data-something attributes but I'm not sure if they can hold "huge" amount of text. Define an object and map element ids to property names in that object. The data I'm storing applies to the page as a whole and not to any specific element, so an element attribute doesn't really work (unless I put it like on the body element, which just seems kinda lame to me especially since my data can be big). Another way you can do it – is put json data inside