Closed cjh9 closed 5 years ago
Hi @yelouafi the example I sent before doesn't work with strings with spaces also...
<body> <script type="module"> import {h, patch, mount} from 'https://unpkg.com/petit-dom?module' const oldVnode = h("div", {}, [ h("div", {}, [ h("h1", {}, ["Text"]), h("div", {}, ["Text"]), h("div", {}, ["Text"]), h("div", {}, ["Text"]), h("div", {}, ["Text"]) ]), h("div", {}, [ h("div", {}, [ " ", h("div", {}, ["Text"]), h("pre", {}, [h("code", {}, [h("span", {}, ["Text"]), " "])]), h("div", {}, []), h("div", {}, []), " " ]) ]), h("p", {}, ["Text"]), " ", h("pre", {}, [h("code", {}, ["Text"])]), h("p", {}, ["Text"]) ]); const newVnode = h("div", {}, [ h("div", {}, [ h("h1", {}, ["Text"]), h("div", {}, ["Text"]), h("div", {}, ["Text"]), h("div", {}, ["Text"]), h("div", {}, ["Text"]) ]), h("div", {}, [ h("div", {}, [ " ", h("div", {}, ["Text"]), h("p", {}, ["Text"]), h("div", {}, []), h("div", {}, []), " " ]) ]), h("pre", {}, [h("code", {}, [h("span", {}, ["Text"]), " "])]), h("p", {}, ["Text"]), " ", h("pre", {}, [h("code", {}, [h("span", {}, ["Text"]), " "])]) ]); document.body.appendChild(mount(oldVnode)) patch(newVnode, oldVnode) </script> </body>
cf v0.2.3
Hi @yelouafi the example I sent before doesn't work with strings with spaces also...