import { compute, h, state } from "../../src" import { renderToString } from "../../src/render-to-string" import { For } from "../../src/performance-helpers"; function Item ( props ) { const $class = compute(() => props.isSelected ? "selected" : "" ) return
ITEM { props.label }
} function getState ( start = 0, total = 1000 ) { return Array.from({ length: total }).map( (_, i) => ({ key: start + i, label: `Label ${start + i}`, isSelected: (start + i) % 2 == 0, })) } const $s1 = state( () => getState(0, 10) ) function App () { return

Deoptigate test

{ item => }
} (async function () { const a = const c1 = renderToString( a ) await $s1.set( () => getState(5, 20) ) const c2 = renderToString( a ) console.log( c1 ) console.log("-----") console.log( c2 ) })()