Skip to content

Local feature store ย #135

@lishine

Description

@lishine

I have a:

  1. [x ] Question: Feel free to just state your question.๐Ÿ˜„
    Hi,

First of all, it is great great lib! After many others, I appreciate all the features here!

  1. I am thinking about a pattern for a store which is local to a set of components, lets call it feature. When a page with this feature renders the store should reseted or created.
    I have a thinking how to do it with a reset action being called at the root component of this feature. Or module variable being assigned to Model(store) in useEffect. The later can be made into custom hook. Maybe you see prettier option? Essentially the second option is similar to your pattern for component store.
    I can add documentation for this pattern.

Another documentation that I can add, is the neat feature - as an example if you push into array but in the component you use the first element, then the component won't be updated.

  1. [ x] Documentation improvement. Creating a PR if you can๐Ÿ‘.

    • [ x] What problem would it solve for you? ๐Ÿ›
    • [x ] Do you think others will benefit from this change as well and it should in core package? ๐Ÿ’ก
    • [x ] Are you willing to (attempt) a PR yourself? โš”

Please tick the appropriate boxes. Feel free to remove the other sections.

Please be sure to close your issues promptly.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions