React Redux showing "e is not a function"!

Hello,

I was about to complete the Drum Machine project, but an unexpected error was thrown while working.

I created the project with React + Redux, and after everything was done, unfortunately, the components did not render. I checked the console for errors and I saw this:

Here e represents the event object, which I use for my event handlers. I don’t know why it is not a function.

I checked my code for errors and I believe there are none. Can someone tell me what I did wrong? Or is this a problem with CodePen?

Link:
https://codepen.io/paulsonjpaul/pen/xxEJGwK?editors=0010

Lines 187-188: You shouldn’t call those methods:

  const selectState = ReactRedux.useSelector();
                                            ^
  const dispatch = ReactRedux.useDispatch();
                                         ^
1 Like

Thank you very much @jenovs. It sorted out the error.

Any other errors in my code? I noticed that the volume slider, change bank toggle and display box doesn’t work and the music takes too much time to play.