-
Notifications
You must be signed in to change notification settings - Fork 156
Description
Summary
This feature would allow users to save repos from various filter settings for example flow:
- selecting two repos with medium popularity
- selecting three rust repos
- selecting few high competition repos
now this feature will allow the user to further add or remove repos and finally arrive at a perfect match for him/her.
show these repo entries in the oss projects page.
Problem
right now every time the user give some parameters and filters repos it just vanishes if he closed and reopens the site or reload the page.
this is kinda annoying to apply filter multiple times to find projects
since we devs tend to explore multiple options before arriving at a final solution
it would be better if the filter allows check boxes instead of radio buttons but a contributor has already added that issue
Proposed Solution
there are two ways of doing this
- save state only for that user (use local storage)
- multi device (save it in db for that user)
here's how i would implement each of this
- local storage.
- create a zustand store
useSavedProjectsStore- an array of saved repos
- save the state if this store to localstorage.
- add
addProjectremoveProjectclearAllSavedfunctions
- saving in db
- create a new column in the user table for savedRepos
an array of json data for saved repos by the user - persist this data across that particular user's sessions (works for multiple devices)
Finally creating appropriate UI components for these
@apsinghdev would love to hear from you whether this feature makes sense or not
and if it does should i proceed with 1'st solution or 2'nd solution
Alternatives Considered
No response
Additional Context
No response