Skip to content

Commit

Permalink
Merge pull request #97 from aurelia/stylelint
Browse files Browse the repository at this point in the history
Replace sass-lint and lesslint with stylelint
  • Loading branch information
3cp authored Nov 14, 2023
2 parents 873b943 + a67f01e commit b627869
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 18 deletions.
3 changes: 0 additions & 3 deletions common/.lesshintrc.json__if_less

This file was deleted.

9 changes: 0 additions & 9 deletions common/.sass-lint.yml__if_sass

This file was deleted.

16 changes: 16 additions & 0 deletions common/.stylelintrc.json__skip-if-exists
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"extends": [
// @if css
"stylelint-config-standard",
// @endif
// @if sass
"stylelint-config-standard-scss",
// @endif
// @if less
"stylelint-config-standard-less",
// @endif
// @if css-module
"stylelint-config-css-modules"
// @endif
]
}
22 changes: 16 additions & 6 deletions common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,26 +27,36 @@
"eslint": "^8.43.0",
"@aurelia/testing": /* @if latest */"latest"/* @endif *//* @if dev */"dev"/* @endif */,
"htmlhint": "^1.1.4",
"stylelint": "^15.11.0",
// @if css
"stylelint-config-standard": "^34.0.0",
// @endif
// @if less
"lesshint": "^6.3.7",
"stylelint-config-standard-less": "^2.0.0",
// @endif
// @if sass
"sass-lint": "^1.13.1",
"stylelint-config-standard-scss": "^11.1.0",
// @endif
// @if css-module
"stylelint-config-css-modules": "^4.3.0",
// @endif
// @if jasmine || mocha
"browser-do": "^4.1.0",
// @endif
},
"scripts": {
"lint:js": "eslint src test/* @if playwright */ e2e/* @endif *//* @if typescript */ --ext .js,.ts/* @endif */",
"lint:js": "eslint src/* @if !no-unit-tests */ test/* @endif *//* @if playwright */ e2e/* @endif *//* @if typescript */ --ext .js,.ts/* @endif */",
// @if css
"lint:css": "stylelint \"src/**/*.css\"",
// @endif
// @if sass
"lint:css": "sass-lint -c .sass-lint.yml \"src/**/*.scss\"",
"lint:css": "stylelint \"src/**/*.scss\"",
// @endif
// @if less
"lint:css": "lesshint \"src/**/*.less\"",
"lint:css": "stylelint \"src/**/*.less\"",
// @endif
"lint:html": "htmlhint -c .htmlhintrc src",
"lint": "npm run lint:js && npm run lint:html/* @if !css */ && npm run lint:css/* @endif */",
"lint": "npm run lint:js && npm run lint:html && npm run lint:css",
// @if jest
"pretest": "npm run lint",
// @endif
Expand Down

0 comments on commit b627869

Please sign in to comment.