add: config

This commit is contained in:
AzizbekFayziyev 2025-06-21 20:26:05 +05:00
parent 7cc76f018f
commit 1f193343a5
6 changed files with 1229 additions and 58 deletions

9
.eslintrc Normal file
View file

@ -0,0 +1,9 @@
{
"extends": ["react-app", "prettier"],
"rules": {
"jsx-quotes": [1, "prefer-double"],
"react-hooks/exhaustive-deps": "off",
"jsonc/json-files": "off"
},
"plugins": ["prettier"]
}

1
.husky/pre-commit Normal file
View file

@ -0,0 +1 @@
npm run precommit

9
.prettierrc Normal file
View file

@ -0,0 +1,9 @@
{
"useTabs": false,
"printWidth": 160,
"tabWidth": 2,
"singleQuote": true,
"trailingComma": "es5",
"jsxBracketSameLine": false,
"semi": true
}

1246
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -26,7 +26,12 @@
"build": "webpack --mode production",
"build:dev": "webpack --mode development --watch",
"test": "react-scripts test",
"eject": "react-scripts eject"
"eject": "react-scripts eject",
"precommit": "lint-staged",
"prepare": "husky"
},
"lint-staged": {
"*.{js,jsx,ts,tsx,css,scss}": ["eslint --fix", "prettier --write"]
},
"eslintConfig": {
"extends": [
@ -64,8 +69,13 @@
"clean-webpack-plugin": "^4.0.0",
"copy-webpack-plugin": "^11.0.0",
"css-loader": "^6.11.0",
"eslint-config-prettier": "^10.1.5",
"eslint-plugin-prettier": "^5.5.0",
"file-loader": "^6.2.0",
"html-webpack-plugin": "^5.6.3",
"husky": "^9.1.7",
"lint-staged": "^16.1.2",
"prettier": "^3.5.3",
"sass": "^1.62.0",
"sass-loader": "^13.3.3",
"style-loader": "^3.3.4",

View file

@ -1,9 +1,9 @@
import React from "react";
import ReactDOM from "react-dom/client";
import App from "./app/App";
import { StoreProvider } from "./app/store/store-reducer";
import React from 'react';
import ReactDOM from 'react-dom/client';
import App from './app/App';
import { StoreProvider } from './app/store/store-reducer';
const root = ReactDOM.createRoot(document.getElementById("root") as HTMLElement);
const root = ReactDOM.createRoot(document.getElementById('root') as HTMLElement);
root.render(
<React.StrictMode>
<StoreProvider>