Thursday, May 23
May. 23rd, 2024 03:19 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Redux is a quite interesting framework for storage. Combined with React – such a nice decomposition of problems. There is an immutable storage, a state, then pure functions called reducers take state and action and produce another successor state. That state is global, and UI components are state machines reflecting that state. Finally, hooks allow interested components watch state changes and render and re-render. Interestingly, they are pushing against templates, those from MVC pattern, saying that “templates separate technologies, not concerns”. So they are not shy of mixing JS with HTML tags as far as those are both used for rendering Views.
Getting up from the subway on the escalator I realized it was heavily raining outside. Pouring, with thunder. I didn’t have an umbrella, but even with an umbrella it’d be hard to stay dry in this rain. Good I didn’t bike – my guts were right this time. I read the emails; “Severe Thunderstorm” was delivered around 9:20; whoops, the weatherman got caught by surprise, again. What’s the weatherman gonna do now? The weatherman is already too noisy mispredicting the rain; should they start mispredicting more heavily? It’s better mispredict the rain than mispredict the sun after all.
The office seemed empty. The chat was quiet too. So, I just focused on my work. Wiring Redux, and making the UI display my states. Four states I counted. Not too bad, but those states are a bit tricky.
In the afternoon I ran into that lady, Olga, whom I saw spoke Russian to someone another day. We spoke; turned out she went to the same school in Moscow as me. Twenty-seven years she worked in this place, and next week she retires. Olga didn't look that old at all: she was thin and wearing stylish dresses and makeup. She introduced me to the other four guys: they all worked together for over twenty years, old-timers. They worked in Brooklyn before moving to the current downtown office. They dislike how everything changes these days. "We were just young," – Olga says. Ed recommended a bunch of food places around, though they are not as good as in Brooklyn; but the thing that he liked Old Xi'an while I thought Famous Xi'an was way better.
I worked till 7 trying to finish that Redux to UI states mapping.