Skip to content

Avoid exposing dispatch from the library #59

@frankdilo

Description

@frankdilo

Hi, thanks for this amazing library.

I have noticed that you expose your internal implementation of dispatch. Haven't investigated if there is a proper reason for doing this, but from the DX point of view it's terrible because all projects that use Redux with VS Code will import it by mistake when what they want to do is really:

const { dispatch } = props;

or

const dispatch = useDispatch();

I would consider not exporting your lib's internal dispatch to outside users of the lib.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions