Skip to content

Commit

Permalink
Prepare 6.0.0 (#123)
Browse files Browse the repository at this point in the history
Co-authored-by: Masafumi Koba <473530+ybiquitous@users.noreply.github.com>
  • Loading branch information
jeddy3 and ybiquitous committed Oct 21, 2021
1 parent 5a51a9d commit 741020d
Show file tree
Hide file tree
Showing 8 changed files with 13,045 additions and 25,250 deletions.
4 changes: 3 additions & 1 deletion CHANGELOG.md
@@ -1,8 +1,10 @@
# Changelog

## Head
## 6.0.0

- Removed: `stylelint` less than `14.0.0` from peer dependencies.
- Removed: `function-calc-no-invalid` rule.
- Added: `custom-property-no-missing-var-function` rule.

## 5.0.0

Expand Down
24 changes: 4 additions & 20 deletions README.md
Expand Up @@ -2,9 +2,9 @@

[![NPM version](https://img.shields.io/npm/v/stylelint-config-recommended.svg)](https://www.npmjs.org/package/stylelint-config-recommended) [![Build Status](https://github.com/stylelint/stylelint-config-recommended/workflows/CI/badge.svg)](https://github.com/stylelint/stylelint-config-recommended/actions)

> The recommended shareable config for stylelint.
> The recommended shareable config for Stylelint.
It turns on all the [_possible errors_](https://stylelint.io/user-guide/rules#possible-errors) rules within stylelint.
It turns on all the [_possible errors_](https://stylelint.io/user-guide/rules/list/#possible-errors) rules within Stylelint.

Use it as is or as a foundation for your own config.

Expand All @@ -16,23 +16,7 @@ npm install stylelint-config-recommended --save-dev

## Usage

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

```json
{
"extends": "stylelint-config-recommended"
}
```

If you've globally installed `stylelint-config-recommended` using the `-g` flag, then you'll need to use the absolute path to `stylelint-config-recommended` in your config e.g.

```json
{
"extends": "/absolute/path/to/stylelint-config-recommended"
}
```

Since [stylelint 9.7.0](https://github.com/stylelint/stylelint/blob/9.7.0/CHANGELOG.md#970), you can simply use the globally installed configuration name instead of the absolute path:
Set your `stylelint` config to:

```json
{
Expand All @@ -42,7 +26,7 @@ Since [stylelint 9.7.0](https://github.com/stylelint/stylelint/blob/9.7.0/CHANGE

### Extending the config

Simply add a `"rules"` key to your config, then add your overrides and additions there.
Add a `"rules"` key to your config, then add your overrides and additions there.

For example, to change the `at-rule-no-unknown` rule to use its `ignoreAtRules` option, turn off the `block-no-empty` rule, and add the `unit-allowed-list` rule:

Expand Down
4 changes: 2 additions & 2 deletions __tests__/index.test.js
Expand Up @@ -4,8 +4,8 @@ const config = require('../');
const fs = require('fs');
const stylelint = require('stylelint');

const validCss = fs.readFileSync('./__tests__/css-valid.css', 'utf-8');
const invalidCss = fs.readFileSync('./__tests__/css-invalid.css', 'utf-8');
const validCss = fs.readFileSync('./__tests__/valid.css', 'utf-8');
const invalidCss = fs.readFileSync('./__tests__/invalid.css', 'utf-8');

describe('flags no warnings with valid css', () => {
let result;
Expand Down
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions index.js
Expand Up @@ -6,6 +6,7 @@ module.exports = {
'block-no-empty': true,
'color-no-invalid-hex': true,
'comment-no-empty': true,
'custom-property-no-missing-var-function': true,
'declaration-block-no-duplicate-custom-properties': true,
'declaration-block-no-duplicate-properties': [
true,
Expand Down

0 comments on commit 741020d

Please sign in to comment.