Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Idea: Rewrite FlowRedux internals with Jetpack Compose #209

Open
sockeqwe opened this issue Sep 19, 2021 · 1 comment
Open

Idea: Rewrite FlowRedux internals with Jetpack Compose #209

sockeqwe opened this issue Sep 19, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@sockeqwe
Copy link
Collaborator

Disclaimer: This is not about changing anything in the DSL per se, this is about rewriting some internals of FlowRedux.

At the moment FlowRedux internally uses Flows as some sort of broadcast channel to publish state changes to the outside but also to the inside (like DSL specific blocks that then trigger) and dispatch actions.

Especially blocks of the DSL (i.e. inState<State> {...}) where cancellation of ongoing background work is required and need to be managed is complex with pure Flows.

@gabrielittner came up with un interesting idea to basically use Jetpack Compose (compiler + runtime) because it is build around State and changes over time on State and has concepts of starting and canceling background work when state changes. That seems to be what we need in FlowRedux and with Compose and @Composable we could probably achieve the same functionality as we have today with our Flow based implementation but with lower complexity (mental overhead) for maintainers of the FlowRedux library itself.

In my head, this is something that we can tackle after FlowRedux 1.0 has been released as the goal is to refacor internals (so private APIs) and not the public API of the DSL etc.

@sockeqwe sockeqwe added the enhancement New feature or request label Sep 19, 2021
@ychescale9
Copy link
Contributor

😄 https://github.com/cashapp/molecule

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

No branches or pull requests

2 participants