Skip to content

Commit

Permalink
fix: get rid of stylelint-csstree-validator
Browse files Browse the repository at this point in the history
  • Loading branch information
limonte committed Mar 7, 2023
1 parent 31989bb commit b17a7f4
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 17 deletions.
5 changes: 1 addition & 4 deletions index.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"stylelint-config-property-sort-order-smacss"
],
"plugins": [
"stylelint-csstree-validator",
"stylelint-order",
"stylelint-scss"
],
Expand All @@ -14,13 +13,11 @@
],
"customSyntax": "postcss-scss",
"rules": {
"declaration-property-value-no-unknown": true,
"alpha-value-notation": null,
"annotation-no-unknown": null,
"at-rule-no-unknown": null,
"color-function-notation": null,
"csstree/validator": {
"syntaxExtensions": ["sass"]
},
"function-no-unknown": null,
"import-notation": null,
"keyframes-name-pattern": null,
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
"postcss-scss": "^4.0.5",
"stylelint-config-property-sort-order-smacss": "^9.0.0",
"stylelint-config-standard": "^30.0.0",
"stylelint-csstree-validator": "^2.0.0",
"stylelint-scss": "^4.3.0"
},
"devDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,13 @@ test('order/properties-order (stylelint-config-property-sort-order-smacss)', asy
assert.strictEqual(output.results[0].warnings[0].text.trim(), 'Expected "top" to come before "color" in group "box" (order/properties-order)')
})

test('csstree/validator (stylelint-csstree-validator)', async () => {
test('declaration-property-value-no-unknown', async () => {
const output = await stylelint.lint({
code: 'a { max-width: auto; }\n',
config,
})
assert.strictEqual(output.results[0].warnings.length, 1)
assert.strictEqual(output.results[0].warnings[0].text.trim(), 'Invalid value for "max-width" (csstree/validator)')
assert.strictEqual(output.results[0].warnings[0].text.trim(), 'Unexpected unknown value "auto" for property "max-width" (declaration-property-value-no-unknown)')
})

test('scss/no-duplicate-dollar-variables (stylelint-scss)', async () => {
Expand Down
13 changes: 3 additions & 10 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -961,9 +961,9 @@ source-map-js@^1.0.1, source-map-js@^1.0.2:
integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==

spdx-correct@^3.0.0:
version "3.1.1"
resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.1.tgz#dece81ac9c1e6713e5f7d1b6f17d468fa53d89a9"
integrity sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==
version "3.2.0"
resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.2.0.tgz#4f5ab0668f0059e34f9c00dce331784a12de4e9c"
integrity sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==
dependencies:
spdx-expression-parse "^3.0.0"
spdx-license-ids "^3.0.0"
Expand Down Expand Up @@ -1034,13 +1034,6 @@ stylelint-config-standard@^30.0.0:
dependencies:
stylelint-config-recommended "^10.0.1"

stylelint-csstree-validator@^2.0.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/stylelint-csstree-validator/-/stylelint-csstree-validator-2.1.0.tgz#1170a0b769ce52149a9047b2d0a6b1a5d085a3dc"
integrity sha512-FKUMEz/iicwkOsY+ohstjlD9dj3qFdAVcw/oVwBDJwToUpwAh/GkvV5FXUd60DoAzn19s1TPsvUuGPbzDo0ZMw==
dependencies:
css-tree "^2.3.1"

stylelint-order@^6.0.2:
version "6.0.2"
resolved "https://registry.yarnpkg.com/stylelint-order/-/stylelint-order-6.0.2.tgz#df54d3ed9aa5a45d4563ada0375e670140a798c2"
Expand Down

0 comments on commit b17a7f4

Please sign in to comment.