WordPress-Coding-Standards/stylelint-config-wordpress

Name: stylelint-config-wordpress

Owner: WordPress Coding Standards

Description: WordPress CSS & SCSS Coding Standards shareable config for stylelint

Created: 2015-07-14 23:20:13.0

Updated: 2018-05-17 16:04:53.0

Pushed: 2018-05-23 19:08:48.0

Homepage:

Size: 486

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

stylelint-config-wordpress

NPM version Build Status Build status

WordPress shareable config for stylelint.

Configuration rules to ensure your CSS is compliant with the WordPress CSS Coding Standards.

Table of Contents
Installation
m install stylelint-config-wordpress --save-dev
Usage

If you've installed stylelint-config-wordpress locally within your project, just set your stylelint config to:


xtends": "stylelint-config-wordpress"

If you've globally installed stylelint-config-wordpress using the -g flag, then you'll need to use the absolute path to stylelint-config-wordpress in your config:


xtends": "/absolute/path/to/stylelint-config-wordpress"

Presets

In addition to the default preset, there is also a SCSS preset. This preset extends both stylelint-config-wordpress and stylelint-config-recommended-scss.

SCSS

xtends": [
"stylelint-config-wordpress/scss"


Extending the config

Simply add a "rules" key to your config and add your overrides there.

For example, to change the indentation to four spaces and turn off the number-leading-zero rule:


xtends": "stylelint-config-wordpress",
ules": {
"indentation": 4,
"number-leading-zero": null


Changelog
License

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.