-
Notifications
You must be signed in to change notification settings - Fork 30.8k
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
Blind snippet insertion #62236
Comments
(Experimental duplicate detection)
|
We can offer these settings: |
I can try those out, but "editor.tabCompletion" : "onlySnippets" sounds like it would disable word suggestions tab completion. This would not be desirable. It is just a matter of priority. To simpliify further...
I could see how this could lead to confusing behaviour though. For example if I am unaware that my current typed string is a snippet, and then a snippet pops in unexpectedly, when I wanted to completion suggestion. Alternative Solution... A new command called editor.hardExecuteSnippet. This command, when run, looks at the immediately typed word at the caret , and inserts the snippet match, regardless of the state of the completion suggestion list. This way, tab completion behaviours are left completely unmolested, but instead there is this one special command that a user could map to hard insert snippets. |
This issue is being closed to keep the number of issues in our inbox on a manageable level, we are closing issues that are not going to be addressed in the foreseeable future: We look at the number of votes the issue has received and the number of duplicate issues filed. More details here. If you disagree and feel that this issue is crucial: We are happy to listen and to reconsider. If you wonder what we are up to, please see our roadmap and issue reporting guidelines. Thanks for your understanding and happy coding! |
I have a workflow problem with snippets and completions.
I have concluded snippets and suggestions are different, and they should be treated separately. At the least, there should be a setting blindSnippetCompletion.
My issue is as follows.
I know my user snippets off by heart. I use them often, and deliberately. I don't need to a list to present my snippets to me. I don't need to shop around in a grocery list of snippets (and other suggestions) to find the right one. I just type the string and hit tab.
I like my snippets to work reliably 100% of the time. So when I type "msg1" followed by the tab key, I want my message write snippet to be placed 100% of the time. I don't want completion suggestions injected by language support extensions unpredictably interrupting my snippet insertion muscle memory.
I don't want any snippets cluttering up my quick suggestions list. Like I mentioned previously, I already know all my snippets, and in some cases I have to cycle through a couple snippets to get to the desired suggestion. I want the suggestions list exclusively for variable, method, and type completions.....not snippets.
With the current settings available in vscode...
"editor.snippetSuggestions": "bottom" Solves issue 3. but exacerbates issue 2.
"editor.snippetSuggestions": "top" Solves issue 2. but exacerbates issue 3.
"editor.snippetSuggestions": "inline" is worst of both worlds.
Enter blindSnippetCompletion.
With this setting enabled, pressing tab (insert snippet), will always prioritise snippet insertion over quick suggestion or intellisense completion. But snippets will never show up in completion suggestions lists.
The text was updated successfully, but these errors were encountered: