eslint-config-ashhitch
v0.1.8
Published
ESLint and Prettier Config with TypeScript Support
Downloads
106
Maintainers
Readme
Eslint and Prettier Setup
These are my settings for ESLint and Prettier
Install
npx install-peerdeps --dev eslint-config-ashhitch
Add to .eslintrc
{
"extends": ["ashhitch"]
}
TypeScript
In your package.json
:
"eslintConfig": {
"extends": "eslint-config-ashhitch/typescript.js",
"parserOptions": {
"project": "./tsconfig.json"
}
},
Then make a `tsconfig.json` file:
{
"extends": "eslint-config-ashhitch/tsconfig.json",
"include": [
"**/*"
]
}
My vs code settings.json config
{
"editor.formatOnSave": true,
"[javascript]": {
"editor.formatOnSave": false
},
"[typescript]": {
"editor.formatOnSave": false
},
"[typescriptreact]": {
"editor.formatOnSave": false
},
"[javascriptreact]": {
"editor.formatOnSave": false
},
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"eslint.enable": true,
"prettier.disableLanguages": ["javascript", "typescript", "typescriptreact", "javascriptreact"],
"npm.packageManager": "yarn",
"typescript.tsdk": "node_modules/typescript/lib"
}