⚙️ Add Prettier config (#647)

This commit is contained in:
Alejandra
2024-03-08 15:10:28 +01:00
committed by GitHub
parent 75adf755b4
commit 0231740213
3 changed files with 11 additions and 1 deletions

8
new-frontend/.prettierrc Normal file
View File

@@ -0,0 +1,8 @@
{
"bracketSpacing": true,
"semi": false,
"singleQuote": true,
"trailingComma": "all",
"printWidth": 80,
"tabWidth": 2
}

View File

@@ -36,6 +36,7 @@
"eslint-plugin-react-hooks": "^4.6.0", "eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react-refresh": "^0.4.4", "eslint-plugin-react-refresh": "^0.4.4",
"openapi-typescript-codegen": "0.25.0", "openapi-typescript-codegen": "0.25.0",
"prettier": "3.2.5",
"typescript": "^5.2.2", "typescript": "^5.2.2",
"vite": "^5.0.0" "vite": "^5.0.0"
} }

View File

@@ -6,7 +6,7 @@
"scripts": { "scripts": {
"dev": "vite", "dev": "vite",
"build": "tsc && vite build", "build": "tsc && vite build",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", "format": "prettier --write ./src/**/*.{ts,tsx,js,jsx,json,md}",
"preview": "vite preview", "preview": "vite preview",
"generate-client": "openapi --input ./openapi.json --useOptions --useUnionTypes --output ./src/client --client axios --exportSchemas true" "generate-client": "openapi --input ./openapi.json --useOptions --useUnionTypes --output ./src/client --client axios --exportSchemas true"
}, },
@@ -39,6 +39,7 @@
"eslint-plugin-react-hooks": "^4.6.0", "eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react-refresh": "^0.4.4", "eslint-plugin-react-refresh": "^0.4.4",
"openapi-typescript-codegen": "0.25.0", "openapi-typescript-codegen": "0.25.0",
"prettier": "3.2.5",
"typescript": "^5.2.2", "typescript": "^5.2.2",
"vite": "^5.0.0" "vite": "^5.0.0"
} }