sapling icon indicating copy to clipboard operation
sapling copied to clipboard

Redux hooks support

Open MajorLift opened this issue 4 years ago • 0 comments

Is your feature request related to a problem? Please describe.

  • Current "Connected to Redux Store" icon implementation only detects connect() function calls, and does not recognize redux hooks.
  • Redux hooks have superseded connect API as the default approach recommended by the react-redux library.

Describe the solution you'd like

  • Display redux store icon for files that use redux hooks:
    1. Check for redux hooks imports.
    2. Check for redux hooks invocation(s).
    3. Check for selector/dispatch/store instance invocation(s). (optional?)

Describe alternatives you've considered N/A

Additional context

  • Example screenshot: Redux store data is being extracted into the component, and redux actions are being dispatched to store, but redux store icon doesn't show up on Sapling tree.
example screenshot

I'd be willing to take a stab at this if it doesn't interfere with core team's plans.

MajorLift avatar Dec 27 '21 16:12 MajorLift