Closed pietrofxq closed 6 years ago
Looks like there is already a closed ticket #20 and a merged solution #17, but it looks like it's not been published yet. I was looking for a way to override this via the config, but didn't find a solution.
new version published
Hey I'm still getting this issue in VSCode. Does this need to be configured?
@reblws what version are you using? and what file extension, I just tested the latest version and it works how it should.
I'm on 2.1.0 -- the extension under postcss-sugarss-language
in the VSCode marketplace.
Using .css
extension. I didn't change "files.associations" in mysettings but I did manually set "Language Mode" to PostCSS.
I checked my mhmadhamster.postcss-language-2.1.0/configurations/language-configuration.json
and it's the same as the change referenced in #17:
{
"comments": {
// symbols used for start and end a block comment. Remove this entry if your language does not support block comments
"blockComment": [ "/*", "*/" ]
},
// symbols used as brackets
"brackets": [
["{", "}"],
["[", "]"],
["(", ")"]
],
// symbols that are auto closed when typing
"autoClosingPairs": [
["{", "}"],
["[", "]"],
["(", ")"],
["\"", "\""],
["'", "'"]
],
// symbols that that can be used to surround a selection
"surroundingPairs": [
["{", "}"],
["[", "]"],
["(", ")"],
["\"", "\""],
["'", "'"]
]
}
I realized that if I hit the shortcut for Toggle Block Comment
it uses the right symbols. I was hitting the shortcut for Toggle Line Comment
before.
It's a little confusing since hitting Toggle Line Comment
outputs //
, but in the default CSS language settings Toggle Line Comment
outputs /* */
When using the postcss syntax, the command
Toggle Line Comment
adds a commentary to the css line using two slashes:This syntax is from SASS commentaries, so this extension should add a comment with the original css syntax: