# Linter & Prettier

***

## AI and DevOps: Heads Up

AI can be pretty bad at everything devops related.

That includes doing project configuration with Vite, Webpack, Linter, Prettier and the likes.

***

## Best Practices

Do NOT install "husky" plugin

Add these plugins, only add these plugins to the existing ones. "@typescript-eslint/parser" "@typescript-eslint/eslint-plugin" "eslint-plugin-react" "eslint-plugin-tailwindcss" "lint-staged"

You may have the add the below config values in the indicated files

***

// package.json

"scripts": { "format": "prettier --write "src/**/\*.{js,ts,jsx,tsx,json,css,md,html}"", "format:check": "prettier --check "src/**/\*.{js,ts,jsx,tsx,json,css,md,html}"", },

"lint-staged": { "src/\*\*/\*.{js,ts,jsx,tsx,json,css,md}": \[ "prettier --write", "eslint --fix" ] }

***

// .editorconfig

root = true

\[\*] charset = utf-8 end\_of\_line = lf insert\_final\_newline = true trim\_trailing\_whitespace = true indent\_style = space indent\_size = 2 max\_line\_length = 120

\[\*.md] trim\_trailing\_whitespace = false

***

// .eslintignore

node\_modules dist build .vite public/mockServiceWorker.js \*.log
