Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Search" Functionality #4

Open
umutphp opened this issue Feb 13, 2020 · 9 comments
Open

"Search" Functionality #4

umutphp opened this issue Feb 13, 2020 · 9 comments
Labels
enhancement New feature or request good first issue Good for newcomers Hacktoberfest help wanted Extra attention is needed

Comments

@umutphp
Copy link
Owner

umutphp commented Feb 13, 2020

It is not a must-do task but needs to be discussed.

  • Check if possible to implement a search
  • Local search or over a service
@umutphp umutphp added enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed labels Feb 13, 2020
@azibom
Copy link

azibom commented Jan 25, 2021

Hi, I like to do this task but if we want to use the promptui and make a seach for it, then it will be like this pic
so are you ok with that?

@umutphp
Copy link
Owner Author

umutphp commented Jan 25, 2021

Hi @azibom ,

Many thanks :), I really appreciate if you do this task. I could not see the pic you linked in the comment. Can you please check it?

@azibom
Copy link

azibom commented Jan 26, 2021

Hi @umutphp, That is the first pic which is in the main page of the promptui (https://github.com/manifoldco/promptui) (and try to search "jajapeno")

@umutphp
Copy link
Owner Author

umutphp commented Jan 26, 2021

ok :).

It is ok for me to use promtui for interface. But the main question is that what we will use for search service. A local storage or a service?

@azibom
Copy link

azibom commented Jan 26, 2021

So you want to fetch all names and then search on it? , I thought you just want to search in the chosen layer

@umutphp
Copy link
Owner Author

umutphp commented Jan 26, 2021

Oh, your idea is better than mine :). I think searching in the chosen layer will be very very ok. It is a pity for me that I did not thought in the way before :).

@umutphp
Copy link
Owner Author

umutphp commented Feb 1, 2021

Hi @azibom ,

Any update or any question to discuss about the topic?

I do not want to bother you, but this feature feature will be a valuable addition to the tool.

@azibom
Copy link

azibom commented Feb 3, 2021

Hi
Thanks for your reminding,
I think the good way is to fetch all the awesome tree names at the first (one problem is how work with this big tree and what is the best data structure for it) and then use the prompt-ui search for search at the first time (for example if you search for the "a" and we have two category "alex" and "abraham", that "alex" is in first layer in tree and "abraham" is in second layer in tree, we show both of them in the list but we consider there position in the tree) and for the next step we just use the select prompt
So that is my idea
first of all tell what do you think about my idea?
And these are my other questions
Is it logical and possible to fetch all the awesome tree at the first step?
What is your idea about the data structure of the awesome tree that we want to work with it?
Thanks @umutphp

@umutphp
Copy link
Owner Author

umutphp commented Feb 3, 2021

Hi @azibom ,

When I created this issue, there were two kinds of search in my mind. First one is the one you explained in your former comment, a search in all of the awesome tree recursively. The second one is a quick search in the first layer of the existing tree node so that user should not walk through all the list to find the list. Let me explain both of the options and my opinions.

Option 1 Search In all Awesome Three
For this, we need all the data of the awesome tree. So, we need to fetch all the data at the first step. But, I am not sure if it is feasible or not. It may also take too much time. And also I think that It may not be possible because the awesome lists are getting bigger and bigger. I think using a third-party service can be a wise solution for this option. There are already two search indexes contains all the awesome lists data under the related section of the main awesome repository. We can use them to perform the queries for user inputs. So, at the first step the user either makes a search or uses the menu to find the repository.

Option 2 Search In Existing Node
For this, we do not need to fetch data. The search will be performed in the child data of the existing node. The data is already fetched to create the list under the node. So, the user can either search in the child nodes or uses the list to find the node.

To sum up, I think It is more feasible to implement the second option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers Hacktoberfest help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants