We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is it possible to do this (simply just run lint-staged on a script already pre-configured in the scripts section?)
"scripts": { "eslint": "./node_modules/.bin/eslint .", "stylelint": "./node_modules/.bin/stylelint statics/css/**/*.less --syntax less", "htmlhint": "./node_modules/.bin/htmlhint mvc/views", "lint": "npm run htmlhint && npm run stylelint && npm run eslint", "lint-staged": "lint-staged" }, "lint-staged" [ "htmlhint", "lesshint", "eslint" ] "pre-commit": [ "lint-staged" ]
The text was updated successfully, but these errors were encountered:
Yes, although because of #17 it won't work in this case. It will after it is fixed.
Important note: you shouldn't pass path to these scripts.
Also, you don't need to specify path to your bins. See https://docs.npmjs.com/cli/run-script
So, to sum it up. In this case your config could look like this:
"scripts": { "eslint": "eslint .", "eslint:staged": "eslint", "stylelint": "stylelint statics/css/**/*.less --syntax less", "stylelint:staged": "stylelint --syntax less", "htmlhint": "htmlhint mvc/views", "htmlhint:staged": "htmlhint", "lint": "npm run htmlhint && npm run stylelint && npm run eslint", "lint-staged": "lint-staged" }, "lint-staged" [ "htmlhint:staged": "*.html", "stylelint:staged": "*.less", "eslint:staged": "*.js" ] "pre-commit": [ "lint-staged" ]
Sorry, something went wrong.
No branches or pull requests
Is it possible to do this (simply just run lint-staged on a script already pre-configured in the scripts section?)
The text was updated successfully, but these errors were encountered: