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

Improve searchability of Bicep snippets & resource names #6249

Open
ucheNkadiCode opened this issue Mar 23, 2022 · 6 comments
Open

Improve searchability of Bicep snippets & resource names #6249

ucheNkadiCode opened this issue Mar 23, 2022 · 6 comments
Labels
devdiv Related to Bicep tooling efforts in DevDiv enhancement New feature or request revisit

Comments

@ucheNkadiCode
Copy link
Contributor

ucheNkadiCode commented Mar 23, 2022

If a user types in "containerapp" wouldn't it be awesome if we could show them related resources even if the name is something gnarly like "Websites.x.y@...". This should also work in the case that a user types in "resource blah ___" . We could allow them to type in "resource containerAppName "containerapp"" and they would be shown all of the resources with a similar tag. They would then be able to hit tab to receive the snippet for this resource.

I propose we start with our most commonly created resources and make them more searchable by adding in aliases for each resource.

What are the most confusing or nonsensical resource names?

@ucheNkadiCode ucheNkadiCode added enhancement New feature or request devdiv Related to Bicep tooling efforts in DevDiv labels Mar 23, 2022
@ghost ghost added the Needs: Triage 🔍 label Mar 23, 2022
@alex-frankel alex-frankel added this to the Committed Backlog milestone Mar 23, 2022
@ucheNkadiCode
Copy link
Contributor Author

ucheNkadiCode commented Mar 26, 2022

@StephenWeatherford mentioned that there doesn't exist away for us to type in "container app" and for intellisense to keep going. I'm wondering if there could be some kind of "search experience" where a user types in "q:" (for query) and this allows IntelliSense to go for longer?

Example

"q: container app" -> User hits Enter and it completes the correct resource for their "query".

@alex-frankel
Copy link
Collaborator

Is the issue the space character?

Do we have any telemetry on the snippet searches people are doing today?

@ucheNkadiCode
Copy link
Contributor Author

@alex-frankel, yes what Stephen explained was that the problem lies in the space character. He mentioned VS Code doesn't support multi-space instellisense which is understandable. I wonder if anyone has a counterexample.

I'll get back to you on the telemetry for snippet searches. The best telemetry I have currently would be "which snippets are users tab completing"

@ucheNkadiCode
Copy link
Contributor Author

From discussion we decided that building functionality with spaces for searching items such as "container app" would be plenty of hassle due to our current tokenizer for very little gain. We are going to go with the implementation that folks just need to type in "containerapp" all one word to take advantage of improved searching

@ucheNkadiCode ucheNkadiCode modified the milestones: Committed Backlog, v0.6 Mar 29, 2022
@ucheNkadiCode ucheNkadiCode changed the title Improve searchability of Bicep snippets Improve searchability of Bicep snippets & resource names Mar 29, 2022
@ucheNkadiCode
Copy link
Contributor Author

ucheNkadiCode commented Mar 29, 2022

In discussion we fleshed this plan out a bit more. There are two scenarios that we like to add descriptions and tagging to create better searchability.

Resource names:

  • resource storageAccount '' <-
    image

and also as snippets

  • res-
    image

Adding information to the description makes it such that a user can type a phrase as one word (e.g "containerinstance") and receive intellisense. Tags on the other hand is a new idea that would allow users to search for resources by their category. For instance anything that is related to Kubernetes could be tagged with k8s, kubernetes, or cluster in addition to the description searchability. This would help with the issue of res- snippets that may have multiple resources wrapped into it. (ex dnsrecord)

Another great idea presented by @StephenWeatherford:

We can use the name that the user has typed, in tandem with the smart resource tagging to fuzzy search for the resource as a starting point for intellisense

image

@alex-frankel
Copy link
Collaborator

Related to #622

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
devdiv Related to Bicep tooling efforts in DevDiv enhancement New feature or request revisit
Projects
None yet
Development

No branches or pull requests

2 participants