Reinventing MobX
summary
Live-coded a minimal MobX: a Proxy‑based observable that records accessed keys, builds a simple derivation graph mapping keys to reactions, and triggers those reactions from setters. Added a React bridge that creates a persistent reaction with useRef and forces re-renders, i.e. an observer for React using useRef that re-renders when tracked observables change. All pieces compile and run in the browser via Parcel; the implementation fits in about fifteen lines for the core observer.
AI-written summary · about








