@g123jp/prettier-config-recommended
v1.2.2
Published
recommended prettier config for frontend projects
Downloads
133
Readme
@g123jp/prettier-config-recommended
recommended prettier config for frontend projects
1. install
yarn add -D @g123jp/prettier-config-recommended
If you are using this config with @g123jp/eslint-config-react already, your all set.
If you are using other eslint configs, you may want to add eslint-config-prettier as well, please follow their docs for the further configuration.
- prettier
- eslint-config-prettier
yarn add -D prettier eslint-config-prettier
2. usage
- package.json
{
"prettier": "@g123jp/prettier-config-recommended"
}
3. ref
4. sample of recommended IDE(vscode) settings
{
"editor.tabSize": 2,
"files.insertFinalNewline": true,
"typescript.tsdk": "node_modules/typescript/lib",
"prettier.requireConfig": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"eslint.validate": [
"javascript",
"javascriptreact",
"typescript",
"typescriptreact"
],
"[json]": {
"editor.defaultFormatter": "vscode.json-language-features",
"editor.formatOnSave": true,
}
}