{"ScriptPreparationCode":null,"TestCases":[{"Name":"Fragment","Code":"const html = \u0060\r\n \u003Cdiv\u003E\r\n \u003Cul\u003E\r\n \u003Cli id=\u0022component\u0022\u003EHello\u003C/li\u003E\r\n \u003C/ul\u003E\r\n \u003C/div\u003E\r\n\u0060\r\nconst fragment = document\r\n .createRange()\r\n .createContextualFragment(html)\r\n .getElementById(\u0027component\u0027)\r\nconsole.log(fragment)","IsDeferred":false},{"Name":"Template 1","Code":"const html = \u0060\r\n \u003Cdiv\u003E\r\n \u003Cul\u003E\r\n \u003Cli id=\u0022component\u0022\u003EHello\u003C/li\u003E\r\n \u003C/ul\u003E\r\n \u003C/div\u003E\r\n\u0060\r\nconst template = document.createElement(\u0027template\u0027)\r\ntemplate.innerHTML = html\r\nconst template1 = Array(3).fill().reduce((template, current) =\u003E template.firstElementChild, template.content)\r\nconsole.log(template1)","IsDeferred":false},{"Name":"Template 2","Code":"const html = \u0060\r\n \u003Cdiv\u003E\r\n \u003Cul\u003E\r\n \u003Cli id=\u0022component\u0022\u003EHello\u003C/li\u003E\r\n \u003C/ul\u003E\r\n \u003C/div\u003E\r\n\u0060\r\nconst template = document.createElement(\u0027template\u0027)\r\ntemplate.innerHTML = html\r\nconst template2 = template.content.getElementById(\u0027component\u0027)\r\nconsole.log(template2)","IsDeferred":false},{"Name":"Parser","Code":"const html = \u0060\r\n \u003Cdiv\u003E\r\n \u003Cul\u003E\r\n \u003Cli id=\u0022component\u0022\u003EHello\u003C/li\u003E\r\n \u003C/ul\u003E\r\n \u003C/div\u003E\r\n\u0060\r\nconst parser = new DOMParser().parseFromString(html, \u0027text/html\u0027).getElementById(\u0027component\u0027)\r\nconsole.log(parser)","IsDeferred":false}]}