The latest MobX 6.0.1 release has a syntax that appears in the example app at https://codesandbox.io/s/minimal-observer-p9ti4 that I don't understand.
The code is:
const TimerView = observer(({ timer }: { timer: Timer }) => (
<span>Seconds passed: {timer.secondsPassed}</span>
));
The syntax function({arg1,arg2})
I've seen and understand, but not
function({arg1: {arg1: arg2}})
and since the MobX docs don't help; I'm asking here.
What I've tried
So I looked up the docs for MobX observer and found https://mobx.js.org/api.html#observer-1 which doesn't help. It says:
observer
Usage: observer(component)
A higher order component you can use to make a functional or class based React component re-render when observables change.
I'm looking over the website more but hopefully this question and forthcoming answer will help someone else out.