0
Challenge · 102Interview Prep
Common Component Builds
Interviewused in ~85% of apps
The live-coding round almost never asks for a novel algorithm — it asks you to build a star-rating, a typeahead, a modal, tabs, or an accordion from a blank file in 20 minutes, talking as you go. These are the same six or seven widgets, every company. Drill them until they are muscle memory and you walk into the room calm.
Core idea. Each classic build is a tiny state machine: pick the one piece of state that drives the UI (an active id, an open flag, a rating number, a query string), render the rest as a pure function of it, and wire events back to the setter. Master that pattern and every widget collapses into the same three moves.
poke it, drag it,
try to break it
try to break it
no slides here.
you drive.
you drive.
Playground, this isn't a screenshot
THE LIVE-CODING GALLERY — PICK A BUILD, THEN USE IT
value: 0 / 5
Each one is ~20–40 lines and tests a distinct skill. Practise until you can write any of them from a blank file in under 10 minutes.
↑ play a little first, then dig in