1.1.2 • Published 8 years ago

stylelint-no-z-index v1.1.2

Weekly downloads
430
License
MIT
Repository
github
Last release
8 years ago

stylelint-no-z-index

Stylelint rule for preventing the use of z-index

Install

npm install --save-dev stylelint-no-z-index

Usage

// .stylelintrc
{
  "plugins": [
    "stylelint-no-z-index"
  ],
  "rules": {
   // ...
   "plugin/no-z-index": 2,
   // ...
  }
}

Example of rules that will pass the linting:

.foo {
   background: red;
}

.foo {
   z-index: auto;
}

.foo {
   z-index: inherit;
}

.foo {
   z-index: initial;
}

.foo {
   z-index: unset;
}

.foo {
   z-index: var(--z-index--default);
}

Example of rules that won't pass the linting:

.foo {
  z-index: -1;
}

.foo {
  z-index: 0;
}

.foo {
  z-index: 100;
}
1.1.2

8 years ago

1.1.1

8 years ago

1.1.0

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago