{"ScriptPreparationCode":null,"TestCases":[{"Name":"Assign","Code":"const a = {\r\n Color: \u0027red\u0027,\r\n Font: \u0027big\u0027\r\n};\r\n\r\nconst colA = [\r\n {\r\n Name: \u0027cola\u0027\r\n },\r\n {\r\n Name: \u0027colb\u0027\r\n }\r\n];\r\n\r\ncolA.forEach(item =\u003E {\r\n Object.assign(item, a);\r\n});\r\n\r\n","IsDeferred":false},{"Name":"Spread","Code":"const a = {\r\n Color: \u0027red\u0027,\r\n Font: \u0027big\u0027\r\n};\r\n\r\nconst colA = [\r\n {\r\n Name: \u0027cola\u0027,\r\n ...a\r\n },\r\n {\r\n Name: \u0027colb\u0027,\r\n ...a\r\n }\r\n];","IsDeferred":false},{"Name":"For for","Code":"const a = {\r\n Color: \u0027red\u0027,\r\n Font: \u0027big\u0027\r\n};\r\n\r\nconst colA = [\r\n {\r\n Name: \u0027cola\u0027\r\n },\r\n {\r\n Name: \u0027colb\u0027\r\n }\r\n];\r\n\r\nfor (let i = 0; i \u003C colA.length; i\u002B\u002B) {\r\n const item = colA[i];\r\n for (const key in a) {\r\n item[key] = a[key];\r\n }\r\n}\r\n\r\n","IsDeferred":false}]}