It seems unnecessary to manage the initialSearchValue property passed to the <Header> component within the <Index> component using state.
Furthermore, since the state setter function is not being called and it's clear that only null is being passed to initialSearchValue, I believe the pkg state variable should be removed and null should be explicitly passed to initialSearchValue.
If there's a need to manage it using state, you can always switch back to managing it with state when necessary, which I think is not the case currently.
It seems unnecessary to manage the
initialSearchValue
property passed to the<Header>
component within the<Index>
component using state.Furthermore, since the state setter function is not being called and it's clear that only
null
is being passed toinitialSearchValue
, I believe thepkg
state variable should be removed andnull
should be explicitly passed toinitialSearchValue
.If there's a need to manage it using state, you can always switch back to managing it with state when necessary, which I think is not the case currently.