This repository has been archived by the owner on Apr 27, 2023. It is now read-only.
Refactor Saka search modes to use React best practices #69
Labels
maintenance
This issue is not a feature but instead some refactoring that improves the code quality
Milestone
Saka currently relies on mode specific providers and "dumb" components to render search results for the selected mode. We currently define a "dumb" component for each search mode. This is done so that we can set certain things like the icon and color for each suggestion as they differ between each type of suggestion.
We should refactor Saka to have a single generic suggestion component that accepts props that define all the suggestion specific parameters.
The refactoring will make the code a lot easier to understand and maintain.
Some related docs:
https://reactjs.org/docs/composition-vs-inheritance.html
https://reactjs.org/docs/components-and-props.html
The text was updated successfully, but these errors were encountered: