Closed cneuwirt closed 5 months ago
You probably need to insert the bindable object in the view body, similar to how you need to handle using observation with environment.
Ok, I'll investigate. I actually think it is a current consequence (limitation) of using the new @Observable macro. The removal of @Binding requirement on properties requires creating explicit Publishers if needed for Combine subscriptions.
Just forgo the onReceive handler and use onChange(of:).
Are there any plans to support @Bindable attribute on @Injected properties. I need the ability to access these bindings so use Combine publisher combinators.
e.g.
I have the following @Bindable @Injected(.stateController) private(set) var stateController
However, I get an error "Type annotation missing in pattern"
I need to access it like Publishers.CombineLatest4(stateController.$schedules, ...