Skip to content
This repository was archived by the owner on Apr 8, 2023. It is now read-only.

mrmlnc/vscode-csscomb

Repository files navigation

vscode-csscomb

VS Code plugin for CSScomb — CSS coding style formatter

Install

  • Press F1 and select Extensions: Install Extensions.
  • Search for and select csscomb.

See the extension installation guide for details.

Usage

Press F1 and run the command named CSSComb.

Supported languages

  • CSS
  • Less
  • SCSS
  • Sass

Supported settings

csscomb.preset

  • Type: Object or String
  • Defaut: {}

Config's name. Should be one of the following: csscomb, zen, yandex or an object containing custom configuration or path to config.

Warning!

If you want to specify a file in the current directory, the path must begin with a ./ or ../ if relative to the current directory. Also you can use HOME directory as ~ symbol.

csscomb.formatOnSave

  • Type: Boolean
  • Default: false

Auto format on save.

csscomb.ignoreFilesOnSave

  • Type: Array
  • Default: []
  • Example: ["variables.less", "mixins/**/*"]

An optional array of glob-patterns to ignore files on save.

csscomb.useLatestCore

  • Type: Boolean
  • Default: false

Use CSScomb v4.0.0 see as fork without babel-polyfill.

For example:

{
  "csscomb.formatOnSave": true,
  "csscomb.preset": "yandex",
  "csscomb.preset": {
    "remove-empty-rulesets": true,
    "always-semicolon": true
  }
}

Keyboard shortcuts

For changes keyboard shortcuts, create a new rule in File -> Preferences -> Keyboard Shortcuts:

{
  "key": "ctrl+shift+c",
  "command": "csscomb.execute"
}

Custom configuration

Custom configuration is fun and simple: just put .csscomb.json file in the project root or your HOME directory.

You can read more about available options in docs.

How to run tests?

  • Close all instances of VS Code
  • Run npm run build command

Changelog

See the Releases section of our GitHub project for changelogs for each release version.

License

This software is released under the terms of the MIT license.

About

🔌 VS Code plugin for CSScomb — CSS coding style formatter.

Topics

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Sponsor this project

Packages

 
 
 

Contributors

Languages