coc-css
chemzqmCss extension for coc.nvim
Published Package Summary
coc-css
Css language server extension for coc.nvim.
Uses vscode-css-languageservice inside.
Note: words are exetracted by iskeyword option of buffer, you may want to
adjust it by command like:
autocmd FileType css setl iskeyword+=-
Note configuration css.enable and wxss support removed from 2.0.0.
Install
In your vim/neovim, run the command:
:CocInstall coc-css
For scss files, you may need use:
autocmd FileType scss setl iskeyword+=@-@
in your vimrc for add @ to iskeyword option.
Features
All features that vscode-css-languageservice provide should work.
doValidationanalyzes an input string and returns syntax and lint errros.doCompleteprovides completion proposals for a given location.doHoverprovides a hover text for a given location.findDefinitionfinds the definition of the symbol at the given location.findReferencesfinds all references to the symbol at the given location.findDocumentHighlightsfinds all symbols connected to the given location.findDocumentSymbolsprovides all symbols in the given documentdoCodeActionsevaluates code actions for the given location, typically to fix a problem.findColorSymbolsevaluates all color symbols in the given documentdoRenamerenames all symbols connected to the given location.getFoldingRangesreturns folding ranges in the given document.formatformat css/scss/less files.
License
MIT
- Css extension for coc.nvim
- onLanguage:css
- onLanguage:less
- onLanguage:scss
Want to build, test, or contribute to coc.nvim extensions? Explore our official SDK and testing toolkits.
Open Developer GuideVersion History
Published with coc-css@2.1.0 as history.md.
v2.0.0 2022-11-03
- Format support.
- Remove configuration
css.enable - Remove support for wxss.
Contributed Commands
All contributes.commands entries from the published package manifest for coc-css@2.1.0.
This package does not declare any contributed commands.
Configuration Schema
All contributes.configuration entries from the published package manifest, including each raw property schema for coc-settings.json.
Raw JSON Schema
{
"type": "array",
"items": {
"type": "string"
},
"default": [],
"description": "Extra arguments for node which start language server."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Enables or disables all validations."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Enables or disables all validations."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Enables or disables all validations."
}Raw JSON Schema
{
"type": "array",
"items": {
"type": "string"
},
"scope": "resource",
"default": [],
"markdownDescription": "A list of relative file paths pointing to JSON files following the [custom data format](https://github.com/microsoft/vscode-css-languageservice/blob/master/docs/customData.md).\n\nVS Code loads custom data on startup to enhance its CSS support for the custom CSS properties, at directives, pseudo classes and pseudo elements you specify in the JSON files.\n\nThe file paths are relative to workspace and only workspace folder settings are considered."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Avoid using `float`. Floats lead to fragile CSS that is easy to break if one aspect of the layout changes."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "IE hacks are only necessary when supporting IE7 and older."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Avoid using `float`. Floats lead to fragile CSS that is easy to break if one aspect of the layout changes."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Avoid using `float`. Floats lead to fragile CSS that is easy to break if one aspect of the layout changes."
}Raw JSON Schema
{
"enum": [
"off",
"messages",
"verbose"
],
"type": "string",
"scope": "window",
"default": "off",
"description": "Traces the communication between VS Code and the CSS language server."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "IE hacks are only necessary when supporting IE7 and older."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "IE hacks are only necessary when supporting IE7 and older."
}Raw JSON Schema
{
"type": "boolean",
"scope": "window",
"default": true,
"description": "Enable/disable default CSS formatter."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Do not use `width` or `height` when using `padding` or `border`."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Avoid using `!important`. It is an indication that the specificity of the entire CSS has gotten out of control and needs to be refactored."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "No unit for zero needed."
}Raw JSON Schema
{
"type": "boolean",
"scope": "window",
"default": true,
"description": "Enable/disable default LESS formatter."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Do not use `width` or `height` when using `padding` or `border`."
}Raw JSON Schema
{
"type": "boolean",
"scope": "window",
"default": true,
"description": "Enable/disable default SCSS formatter."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Do not use `width` or `height` when using `padding` or `border`."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Do not use empty rulesets."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Selectors should not contain IDs because these rules are too tightly coupled with the HTML."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Avoid using `!important`. It is an indication that the specificity of the entire CSS has gotten out of control and needs to be refactored."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "No unit for zero needed."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "Avoid using `!important`. It is an indication that the specificity of the entire CSS has gotten out of control and needs to be refactored."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "No unit for zero needed."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Show references to MDN in CSS hovers."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Do not use empty rulesets."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Selectors should not contain IDs because these rules are too tightly coupled with the HTML."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Do not use empty rulesets."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Selectors should not contain IDs because these rules are too tightly coupled with the HTML."
}Raw JSON Schema
{
"enum": [
"collapse",
"expand"
],
"type": "string",
"scope": "resource",
"default": "collapse",
"markdownDescription": "Put braces on the same line as rules (`collapse`) or put braces on own line (`expand`)."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "When using a vendor-specific prefix, also include the standard property."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Show references to MDN in LESS hovers."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Show references to MDN in SCSS hovers."
}Raw JSON Schema
{
"enum": [
"collapse",
"expand"
],
"type": "string",
"scope": "resource",
"default": "collapse",
"markdownDescription": "Put braces on the same line as rules (`collapse`) or put braces on own line (`expand`)."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "When using a vendor-specific prefix, also include the standard property."
}Raw JSON Schema
{
"enum": [
"collapse",
"expand"
],
"type": "string",
"scope": "resource",
"default": "collapse",
"markdownDescription": "Put braces on the same line as rules (`collapse`) or put braces on own line (`expand`)."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "When using a vendor-specific prefix, also include the standard property."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Show tag and attribute documentation in CSS hovers."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "error",
"description": "Hex colors must consist of three or six hex numbers."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Unknown at-rule."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Import statements do not load in parallel."
}Raw JSON Schema
{
"type": "array",
"items": {
"type": "string"
},
"scope": "resource",
"default": [],
"description": "A list of properties that are not validated against the `unknownProperties` rule.",
"uniqueItems": true
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Show tag and attribute documentation in LESS hovers."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "error",
"description": "Hex colors must consist of three or six hex numbers."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Unknown at-rule."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Show tag and attribute documentation in SCSS hovers."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "error",
"description": "Hex colors must consist of three or six hex numbers."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Unknown at-rule."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Import statements do not load in parallel."
}Raw JSON Schema
{
"type": "array",
"items": {
"type": "string"
},
"scope": "resource",
"default": [],
"description": "A list of properties that are not validated against the `unknownProperties` rule.",
"uniqueItems": true
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Import statements do not load in parallel."
}Raw JSON Schema
{
"type": "array",
"items": {
"type": "string"
},
"scope": "resource",
"default": [],
"description": "A list of properties that are not validated against the `unknownProperties` rule.",
"uniqueItems": true
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "The universal selector (`*`) is known to be slow."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Unknown property."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Whether existing line breaks before elements should be preserved."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"markdownDescription": "`@font-face` rule must define `src` and `font-family` properties."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "The universal selector (`*`) is known to be slow."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Unknown property."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"markdownDescription": "The universal selector (`*`) is known to be slow."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"description": "Unknown property."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Do not use duplicate style definitions."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Whether existing line breaks before elements should be preserved."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"markdownDescription": "`@font-face` rule must define `src` and `font-family` properties."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Whether existing line breaks before elements should be preserved."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"markdownDescription": "`@font-face` rule must define `src` and `font-family` properties."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Do not use duplicate style definitions."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Do not use duplicate style definitions."
}Raw JSON Schema
{
"type": [
"number",
"null"
],
"scope": "resource",
"default": null,
"markdownDescription": "Maximum number of line breaks to be preserved in one chunk, when `#css.format.preserveNewLines#` is enabled."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Separate rulesets by a blank line."
}Raw JSON Schema
{
"type": [
"number",
"null"
],
"scope": "resource",
"default": null,
"markdownDescription": "Maximum number of line breaks to be preserved in one chunk, when `#less.format.preserveNewLines#` is enabled."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Separate rulesets by a blank line."
}Raw JSON Schema
{
"type": [
"number",
"null"
],
"scope": "resource",
"default": null,
"markdownDescription": "Maximum number of line breaks to be preserved in one chunk, when `#scss.format.preserveNewLines#` is enabled."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Separate rulesets by a blank line."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "error",
"description": "Invalid number of parameters."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "When using a vendor-specific prefix make sure to also include all other vendor-specific properties."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Separate selectors with a new line."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "error",
"description": "Invalid number of parameters."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "When using a vendor-specific prefix make sure to also include all other vendor-specific properties."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "error",
"description": "Invalid number of parameters."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "When using a vendor-specific prefix make sure to also include all other vendor-specific properties."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Separate selectors with a new line."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"markdownDescription": "Separate selectors with a new line."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"markdownDescription": "Property is ignored due to the display. E.g. with `display: inline`, the `width`, `height`, `margin-top`, `margin-bottom`, and `float` properties have no effect."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"markdownDescription": "Property is ignored due to the display. E.g. with `display: inline`, the `width`, `height`, `margin-top`, `margin-bottom`, and `float` properties have no effect."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "warning",
"markdownDescription": "Property is ignored due to the display. E.g. with `display: inline`, the `width`, `height`, `margin-top`, `margin-bottom`, and `float` properties have no effect."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": false,
"markdownDescription": "Ensure a space character around selector separators '>', '+', '~' (e.g. `a > b`)."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Unknown vendor specific property."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": false,
"markdownDescription": "Ensure a space character around selector separators '>', '+', '~' (e.g. `a > b`)."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": false,
"markdownDescription": "Ensure a space character around selector separators '>', '+', '~' (e.g. `a > b`)."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Unknown vendor specific property."
}Raw JSON Schema
{
"enum": [
"ignore",
"warning",
"error"
],
"type": "string",
"scope": "resource",
"default": "ignore",
"description": "Unknown vendor specific property."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Insert semicolon at end of line when completing CSS properties."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "By default, VS Code triggers property value completion after selecting a CSS property. Use this setting to disable this behavior."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Insert semicolon at end of line when completing CSS properties."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "Insert semicolon at end of line when completing CSS properties."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "By default, VS Code triggers property value completion after selecting a CSS property. Use this setting to disable this behavior."
}Raw JSON Schema
{
"type": "boolean",
"scope": "resource",
"default": true,
"description": "By default, VS Code triggers property value completion after selecting a CSS property. Use this setting to disable this behavior."
}