Keep Mbak Maya's census register running in Svelte 5: keyed each, runes, actions, SSR, tests. 14 levels, played right in the browser with nothing to install.
What the levels ask
Ms. Wulan writes pindah Klaten in the note of the resident on the third row, then taps Urut nama. The note has to stay beside the same resident, wherever that resident lands after the sort. Complete the head of {#each} in App.svelte.
Mrs. Ratna writes pindah Solo on the third row, taps Urut nama, then Kirim. Her note has to stay on its resident’s row and the village office has to receive 1 catatan terkirim. Complete the two holes in App.svelte.
Mr. Tono’s phone is the cheapest at the post, with little memory. He searches for sri among 4,812 residents, then marks the resident on the second row pindah. That list is only read and replaced whole, so the register may wrap no more than 100 objects in a proxy, and the moved mark has to show. Complete the two holes in App.svelte.
Bagas types pindah in the note on the second row, then opens the Rekap tab for the neighbourhood head. The summary per neighbourhood has to be counted only once, when that tab opens, not on every letter. Complete the hole in App.svelte.
Dina types pindah in the note on the first row, then sorts by Umur. While she types, the register must not sort 4,812 residents again; once she picks Umur, the order is worked out once. Complete the hole in $derived.by.
Mr. Jaya types Siti to check a name against the district’s data. Every letter sends a search, and a search for a shorter word answers later. Once every answer is in, the screen has to show the results for "Siti". Complete the hole in App.svelte.
The neighbourhood head goes back and forth between Daftar and Rekap three times for the village office meeting. The chart is made by chart.js through the action grafik. Every time Rekap closes, its chart has to go too: no chart may stay alive without a canvas on the screen. Complete the hole in the action.
Reports of a baby born and a newcomer come in from Neighbourhood 3. The neighbourhood head adds one twice, goes to Daftar, back to Rekap, then to Daftar again. The chart is put on with {@attach} and made again every time its numbers change: there must always be exactly one chart alive on Rekap, and none on Daftar.
Dina goes back to Rekap three times, then turns her phone sideways for a wider chart. The chart has to be measured again once for one turn, and after she goes back to Daftar no window listener may be left behind. Complete the two holes in Rekap.svelte.
Grandma Marni’s age has not been filled in, and the average age in the summary cannot be worked out. Bagas still needs his list of residents. The list has to show, and where the summary goes the words Rekap belum bisa dibuat appear. Complete the hole in App.svelte.
From today the post laptop renders the first page on the server so cheap phones see the list at once. Ms. Wulan opens the page for RT 3, then Mr. Tono opens the page of every resident. Mr. Tono’s page must not be filtered to Neighbourhood 3. Complete the two holes, in App.svelte and Daftar.svelte.
Since the filter moved into a context, Ms. Wulan taps RT 3 and then RT 7 on her phone, and her list does not change. The list has to follow every choice. Complete the two holes in App.svelte.