Skip to content

Improve useEffect: include dependencies and introduce additional effect which stops scanner when component unmounts #258

@spaudanjo

Description

@spaudanjo

Current behavior

Updating properties (e.g. constraints) currently doesn't make the scanner behaviour adapt/reflect these updates. This is because these properties are not in the dependencies array of the useEffect within hooks.ts.

Proposal

Adding the missing dependencies to the useEffect and introducing an additional useEffect` which exclusively does the scanner stopping when the component unmounts.

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