-
Hello Pointfree + community, I am currently trying out whether TCA is a framework that I want to use for my applications, or whether I should go more into a direction like showcased in the Modern Swift UI episodes. Something that I noticed is that the behaviour when it comes to unsubscribing from an external datasource seems to behave differently. As an example: I have a parent feature that presents a sheet which has its own feature. When doing this in the "Modern Swift UI" way it correctly unsubscribes once the child feature is popped from the stack. When doing the same thing in TCA it does not unsubscribe. This is problematic since the subscription should only be active when the child feature is presented. Can anybody maybe explain to me why it behaves differently and whether there is a way to make unsubscription behave the same in TCA? Looking forward to the answer and thank you for theses amazing libraries :) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hi @Kaeldehta, it's hard to say without seeing some code. Can you please share a small demo project that shows the behavior you are seeing in TCA vs SwiftUI? |
Beta Was this translation helpful? Give feedback.
Hi @Kaeldehta, thanks for that! I was able to see the behavior you are describing, and luckily it's fixed on TCA
main
. We will get a 1.19 release for that soon and then everything should be fixed. 🙂