'JSX props should not use functions react/jsx-no-bind

i am forking a app. but in gives me this errors. instead or arrow function what should i use or should i download any dependencies?

here is the code

    const modalBottom = () => {
    return (
      <ConfirmAddModalBottom
        price={price}
        currencies={currencies}
        parsedAmounts={parsedAmounts}
        noLiquidity={noLiquidity}
        onAdd={onAdd}
        poolTokenPercentage={poolTokenPercentage}
      />
    )
  }

error: 8: JSX props should not use functions react/jsx-no-bind



Solution 1:[1]

Maybe you could try to install jsx with npm . Like this:

npm install -g jsx

If u have any question let me know. I am also forking PCS.

Solution 2:[2]

I found that the problem was solved by following the eslint documentation to this section.

Essentially, move any of your functions into a useCallback hook and that should stop the error.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 TG-Nahuel_ma99
Solution 2 JimmyTheCode