pastelsky / tsdocs

Browse type documentation for JS libraries
https://tsdocs.dev
MIT License
1.13k stars 25 forks source link

Removed unnecessary state from Index component #21

Closed takagimeow closed 11 months ago

takagimeow commented 11 months ago

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.