eslint-home-agency
Linting rules for HOME dev projects.
.eslintrc.js
Eslint files should be in at least the following folders.
/
/frontend
/backend
/cms
/integration
To use in the given folder
(Add home config as a dependency in every folder that has a .eslintrc it's own package.json)
npm i -D @home_agency/eslint-config-home-agency
- Create an eslintrc.js file
- Include the relevant lint
- All lint files can be extended using standard lint rules. Use this for project specific items. For example aliases.
Base lint (.eslintrc.js)
module.exports = {
extends: [
`@home_agency/eslint-config-home-agency/eslint/base`
]
};
Required dev dependencies
"@commitlint/cli": "^12.1.4",
"@commitlint/config-conventional": "^12.1.4",
"commitlint": "^12.1.4",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-import-quotes": "0.0.1",
"eslint-plugin-jest": "^24.4.0",
"eslint-plugin-no-unsanitized": "^3.1.5",
"eslint-plugin-prettier": "^3.4.0",
"eslint-plugin-promise": "^5.1.0",
"eslint-plugin-scanjs-rules": "^0.2.1",
"eslint-plugin-security": "^1.4.0",
"prettier": "^2.3.2",
"prettier-eslint": "^13.0.0"
React lint (.eslintrc.js)
module.exports = {
extends: [
`@home_agency/eslint-config-home-agency/eslint/react`
]
};
"deepmerge": "^4.2.2",
"eslint-config-airbnb": "^18.2.1",
"eslint-import-resolver-alias": "^1.1.2",
"eslint-plugin-import": "^2.24.0",
"eslint-plugin-jsx-a11y": "^6.4.1",
"eslint-plugin-no-unsanitized": "^3.1.5",
"eslint-plugin-no-wildcard-postmessage": "^0.2.0",
"eslint-plugin-prototype-pollution-security-rules": "^1.0.6",
"eslint-plugin-react": "^7.24.0",
"eslint-plugin-react-hooks": "^4.2.0",
"jest": "^27.1.1",
Integration lint (.eslintrc.js)
module.exports = {
extends: [
`@home_agency/eslint-config-home-agency/eslint/integration`
]
};
"eslint-plugin-jest": "^24.3.6",
"eslint-plugin-security": "^1.4.0",
"eslint-plugin-webdriverio": "^1.0.1",