Mark Malstrom

@malstrom.me

Wake me up when the DEFCON levels have changed. They/them. https://malstrom.me

Taking a poll to try and find some meaning in my life: what do folks who don't live with someone else even do after work? I guess I need more non-programming hobbies…

For a long while, ~ I've felt no benchmark (that I know of) has captured the relationship between ~ reactivity and rendering We have rendering benchmarks. We have reactivity benchmarks. I had to make my own. I did not expect these results

Bild

Happy to announce Octane – the successor to Inferno. React’s programming model, compiled. Hooks, Suspense and Actions, compiled ahead of time. No virtual DOM. No Rules of Hooks. No manually maintained dependency arrays. The compiler understands what your code. octanejs.dev

// Counter.tsrx — hooks next to output, no rules of hooks
import { useState, useEffect } from 'octane';

export function Counter(props) @{
	const [count, setCount] = useState(0);

	// A hook behind a condition is fine — slots are
	// assigned by call site, not call order.
	if (!props.paused) {
		useEffect(() => {
			console.log('count is now', count);
		}); // the compiler infers [count]
	}

	<button onClick={() => setCount(count + 1)}>{'Count: ' + count}</button>
}