If I want to subscribe to four @Published variables at the same time, I can do something like the following.
Publishers.CombineLatest4($variable0, $variable1, $variable2, $variable3)
I wonder if there is any solution to subscribing to more than four variables at the same time?
Muchos thankos
I guess it goes like the following.
Publishers.CombineLatest4($variable0, $variable1, $variable2, $variable3)
.combineLatest($variable4)
.combineLatest($variable5)
.sink { completion in
} receiveValue: { response0, response1 in
let variable = response0.0
let variable4 = response0.1
let variable5 = response1
let v0 = variable.0
let v1 = variable.1
let v2 = variable.2
let v3 = variable.3
}.store(in: &cancellables)
It's kind of odd.