Coding "Tomato 2" for macOS with SwiftUI - EP2

Опубликовано: 23 Июнь 2026
на канале: Focusmark
376
7

I added an "environment object" that keeps track of "session start time". Also connected Start/Pause button to update the environment object.

Didn't get much more done. Will have to study the Combine framework a little bit, because I don't understand it enough at the moment...

My goal is to somehow automatically update my state variables each second – but without writing any imperative code.

I used to be able to do that with ReactiveCocoa, so need to find a way to do it with Combine.