-
Notifications
You must be signed in to change notification settings - Fork 29.2k
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
Emmet and Intellisense overlap in SCCS files #1952
Comments
CC @aeschli What is happening is that the Intellisense provided by Code for SCCS files and Emmet overlap in this case. When you start typing then Intellisense is active. To deactivate Intellisense you have to press ESC and then you can press TAB to get the emmet expansion. Emmet works properly when I use the cheatsheet as a reference. You can verify this by invoking
Another approach is to bind the emmet command {
"key": "ctrl+m",
"command": "editor.emmet.action.expandAbbreviation",
"when": "editorTextFocus && !editorHasSelection && !editorHasMultipleSelections && !editorTabMovesFocus"
} Then you can force an emmet expansion using this keybinding. |
It would be great if we could tell Code to prioritize Emmet completion over Intellisense in scenarios such as these. When writing CSS, I would never want |
@brianblakely You can change this in your keybindings file. { "key": "tab", "command": "-acceptSelectedSuggestion"}, if you don't wan't to complete completion-proposals with the tab key. Add
To give emmet priority. |
@aeschli the problem of this solution is that you cannot use [tab] autocompletion in none-sass files (in jsx, for example), you have to press [enter], instead. I think there must be "override" or/and profiles options, or maybe "priority" options in Emmet/IntelliSense, so I'd like to use Emmet in .sass, and also use IntelliSense predictions on tab in other files. |
@YuziRussianHax how about setting "[css]": {
"editor.quickSuggestions": true
} The above will stop the suggestions showing up altogether in css files. The other files would continue to behave as is |
@ramya-rao-a Oh my gosh, I was searching for this solution for so long. (I didnt find way to configure such things for specific language in official documentation). Thank you a lot! |
@YuziRussianHax Also if you do want the suggestions to show up you can always do Happy Coding! |
@aeschli it is not working on the latest vs code OSX version |
@HazelZ What is not working on the latest vs code? |
I don't think the suggestions above are acceptable. There needs to be a setting to prioritise emmet tab completion over quick suggestions. We shouldn't have to give up quick suggestions to make emmet shortcuts work. |
Thank you so much for this improvement ! |
Thanks @ramya-rao-a - this was driving me nuts for a while. |
I'm lost on what needs to be done. I get two suggestions as OP says. What can I do to disable or prioritize emmet autocomplete in scss,sass,css files, if possible also in html, ejs, jsx, jade |
If you want to see emmet in the suggestion list set This will give you emmet in suggestion list for languages that are markup or stylesheet. Eg: html, jade, slim, xml, css, less, scss. In the upcoming release (1.14), to get emmet in suggestion list for jsx, you need to set another setting Read about emmet improvements in the previous release noteshttps://code.visualstudio.com/updates/v1_13#_emmet-abbreviation-expansion-in-suggestion-list as well as in the next release |
@ramya-rao-a thanks, for me "not" setting
|
@ramya-rao-a emmet.useNewEmmet was working great for awhile, but yesterday vscode updated and now it only works sometimes. When I type 'w' I expect the it to be 'width' but right now it's putting 'white-space' instead. |
@atmortensen The suggestion list is shared by the css completion provider and emmet. What you are seeing are suggestions from the css completion provider which trumps the emmet suggestion which is 9th in the list above. Which makes sense... alphabetically speaking. This is by design. If you want emmet specifically you can explicitly use the |
@ramya-rao-a It would be good if the emmet proposals are easier distinguishable. Maybe set the 'detail' to 'emmet' completion, or have your own icon (talk to @jrieken ) |
Well, for a start you could use the snippet type. I believe it used to be like that in the beginning, unsure why it isn't anymore |
Because, then emmet would go to the bottom if anyone had |
Yeah, why not? The default is |
Hm, that surprised me. The default is still |
Keep original settings |
@levinit Not for long... In the next update (1.15) we are switching to the new emmet model completely. Is your reason for disabling the new emmet #1952 (comment) ? |
@ramya-rao-a I just found out that this issue is about the emmet problem in the CSS file。😂 |
@levinit With new emmet enabled don't you get the expanded value for |
The new Emmet experience is now shipped with VS Code 1.15 Tab will no longer trigger Emmet. Please read more on what else is new at Emmet 2.0 |
@ramya-rao-a Maybe I am not understanding fully how I should be using emmet with vscode. The only difference with 2.0 is that now I can't use tab to get the expected snippet. Right now if I type 'w' and press enter it puts 'white-space' instead of 'width' and if I type 'p' and press enter I get 'pad' instead of padding. I understand that it is sorted alphabetically, but I use width a lot more that white-space. Is there a way to put emmet snippets on top? I might just be doing something wrong. Thanks! |
@atmortensen You arent doing anything wrong. The reason for what you are saying has been already discussed in #1952 (comment) We have had feedback on wanting emmet to be triggered on tab, so we are bringing it back in the July Recovery Build of 1.15.1 which will be out in the next few days. Until then you can use the latest Insiders (https://code.visualstudio.com/insiders) and set Am using #32346 to track keeping emmet suggestions on top if we go down the route of treating them as snippets |
Interesting, but for some reason new emmet dosent work in .sass files (indented syntax) at all @ Windows 10 - VS 1.15.0 |
@borisowsky That's been fixed in the latest Insiders (https://code.visualstudio.com/insiders). The fix will be included in the upcoming July Recovery Build (1.15.1) which will be out in 2 days or so |
Emmet is acting up in strange ways.
When I type, as an example, "cp+tab" I expect "cursor: pointer". I know this is not the official emmet abbriviation. But even when I type "cur:p + tab" I get "cur:past" instead of "cursor:pointer". That VS Code extends other things is great. But when I type "cp", I at least expect "cursor: pointer " to be in the autocomplete window.
It's not only an issue with the cursor abbriviation. I have it all the time with others properties too.
This issue can be related to .scss files. I dont' know if it's like that in css files.
Can this be fixed please.
The text was updated successfully, but these errors were encountered: