diff --git a/.stylelintrc.json b/.stylelintrc.json index 40db42c6..cf57a5b0 100644 --- a/.stylelintrc.json +++ b/.stylelintrc.json @@ -1,3 +1,13 @@ { - "extends": "stylelint-config-standard" + "customSyntax": "postcss-scss", + "extends": "stylelint-config-standard", + "plugins": [ + "stylelint-scss" + ], + "rules": { + "at-rule-no-unknown": null, + "import-notation": "string", + "scss/at-rule-no-unknown": true, + "selector-class-pattern": null + } } diff --git a/package-lock.json b/package-lock.json index 2f1453b4..52eaa5eb 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,10 +12,12 @@ "js-beautify": "^1.14.7", "node-html-markdown": "^1.2.2", "node-html-parser": "^6.1.4", + "postcss-scss": "^4.0.6", "prettier": "^2.8.0", "stylelint": "^14.15.0", "stylelint-config-recommended": "^9.0.0", - "stylelint-config-standard": "^29.0.0" + "stylelint-config-standard": "^29.0.0", + "stylelint-scss": "^4.3.0" } }, "node_modules/@babel/code-frame": { @@ -1152,6 +1154,12 @@ "node": ">=8" } }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "dev": true + }, "node_modules/lodash.truncate": { "version": "4.4.2", "resolved": "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz", @@ -1575,6 +1583,28 @@ "postcss": "^8.3.3" } }, + "node_modules/postcss-scss": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/postcss-scss/-/postcss-scss-4.0.6.tgz", + "integrity": "sha512-rLDPhJY4z/i4nVFZ27j9GqLxj1pwxE80eAzUNRMXtcpipFYIeowerzBgG3yJhMtObGEXidtIgbUpQ3eLDsf5OQ==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss-scss" + } + ], + "engines": { + "node": ">=12.0" + }, + "peerDependencies": { + "postcss": "^8.4.19" + } + }, "node_modules/postcss-selector-parser": { "version": "6.0.10", "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz", @@ -2032,6 +2062,22 @@ "stylelint": "^14.14.0" } }, + "node_modules/stylelint-scss": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/stylelint-scss/-/stylelint-scss-4.3.0.tgz", + "integrity": "sha512-GvSaKCA3tipzZHoz+nNO7S02ZqOsdBzMiCx9poSmLlb3tdJlGddEX/8QzCOD8O7GQan9bjsvLMsO5xiw6IhhIQ==", + "dev": true, + "dependencies": { + "lodash": "^4.17.21", + "postcss-media-query-parser": "^0.2.3", + "postcss-resolve-nested-selector": "^0.1.1", + "postcss-selector-parser": "^6.0.6", + "postcss-value-parser": "^4.1.0" + }, + "peerDependencies": { + "stylelint": "^14.5.1" + } + }, "node_modules/stylelint/node_modules/balanced-match": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-2.0.0.tgz", @@ -3083,6 +3129,12 @@ "p-locate": "^4.1.0" } }, + "lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "dev": true + }, "lodash.truncate": { "version": "4.4.2", "resolved": "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz", @@ -3386,6 +3438,13 @@ "dev": true, "requires": {} }, + "postcss-scss": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/postcss-scss/-/postcss-scss-4.0.6.tgz", + "integrity": "sha512-rLDPhJY4z/i4nVFZ27j9GqLxj1pwxE80eAzUNRMXtcpipFYIeowerzBgG3yJhMtObGEXidtIgbUpQ3eLDsf5OQ==", + "dev": true, + "requires": {} + }, "postcss-selector-parser": { "version": "6.0.10", "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz", @@ -3730,6 +3789,19 @@ "stylelint-config-recommended": "^9.0.0" } }, + "stylelint-scss": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/stylelint-scss/-/stylelint-scss-4.3.0.tgz", + "integrity": "sha512-GvSaKCA3tipzZHoz+nNO7S02ZqOsdBzMiCx9poSmLlb3tdJlGddEX/8QzCOD8O7GQan9bjsvLMsO5xiw6IhhIQ==", + "dev": true, + "requires": { + "lodash": "^4.17.21", + "postcss-media-query-parser": "^0.2.3", + "postcss-resolve-nested-selector": "^0.1.1", + "postcss-selector-parser": "^6.0.6", + "postcss-value-parser": "^4.1.0" + } + }, "supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", diff --git a/package.json b/package.json index d9794a53..7bee768b 100644 --- a/package.json +++ b/package.json @@ -10,10 +10,12 @@ "js-beautify": "^1.14.7", "node-html-markdown": "^1.2.2", "node-html-parser": "^6.1.4", + "postcss-scss": "^4.0.6", "prettier": "^2.8.0", "stylelint": "^14.15.0", "stylelint-config-recommended": "^9.0.0", - "stylelint-config-standard": "^29.0.0" + "stylelint-config-standard": "^29.0.0", + "stylelint-scss": "^4.3.0" }, "scripts": { "format": "stylelint --fix ./sass/*.scss && prettier --write *.md content/**/*.md && js-beautify -r templates/base.html",