Skip to content

how can I handle the situation that the storageRequest value depending on previous state #20

@lujiajing1126

Description

@lujiajing1126

In redux, we can get the current state in reducer

how can i get the current state in cycle.js app with storage where i store the state of app

now i can get the current state by

const storageRequest$ = xs.combine(newScreen$.startWith(null),deleteScreen$.startWith(null)).map(([newOne,delOne]) => {
    return state$.map(row => { // where to create a request }
}

but state$ is depend on the storage input stream conversely, so there's circular dependenies

How can i solve this problem ( maybe it' s a flaw of my design pattern )

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions