packages: add lint-staged-config

This commit is contained in:
vchikalkin 2024-11-28 11:45:47 +03:00
parent b159d811b5
commit 1e06d6da23
7 changed files with 28 additions and 10 deletions

View File

@ -0,0 +1 @@
export { default } from '@repo/lint-staged-config/config';

View File

@ -19,6 +19,7 @@
}, },
"devDependencies": { "devDependencies": {
"@repo/eslint-config": "workspace:*", "@repo/eslint-config": "workspace:*",
"@repo/lint-staged-config": "workspace:*",
"@repo/typescript-config": "workspace:*", "@repo/typescript-config": "workspace:*",
"@types/node": "catalog:", "@types/node": "catalog:",
"@types/react": "catalog:", "@types/react": "catalog:",
@ -28,10 +29,5 @@
"postcss": "catalog:", "postcss": "catalog:",
"tailwindcss": "catalog:", "tailwindcss": "catalog:",
"typescript": "catalog:" "typescript": "catalog:"
},
"lint-staged": {
"*.{js,jsx,ts,tsx,md,json}": [
"eslint --fix"
]
} }
} }

View File

@ -0,0 +1,3 @@
export default {
'*.{js,jsx,ts,tsx,md,json}': ['eslint --fix'],
};

View File

@ -0,0 +1,13 @@
{
"name": "@repo/lint-staged-config",
"version": "0.0.0",
"type": "module",
"private": true,
"license": "MIT",
"publishConfig": {
"access": "public"
},
"exports": {
"./config": "./config.mjs"
}
}

View File

@ -0,0 +1 @@
export { default } from '@repo/lint-staged-config/config';

View File

@ -29,6 +29,7 @@
"devDependencies": { "devDependencies": {
"@radix-ui/react-slot": "catalog:", "@radix-ui/react-slot": "catalog:",
"@repo/eslint-config": "workspace:*", "@repo/eslint-config": "workspace:*",
"@repo/lint-staged-config": "workspace:*",
"@repo/typescript-config": "workspace:*", "@repo/typescript-config": "workspace:*",
"@types/react": "catalog:", "@types/react": "catalog:",
"autoprefixer": "catalog:", "autoprefixer": "catalog:",
@ -46,10 +47,5 @@
"dependencies": { "dependencies": {
"react": "catalog:", "react": "catalog:",
"react-dom": "catalog:" "react-dom": "catalog:"
},
"lint-staged": {
"*.{js,jsx,ts,tsx,md,json}": [
"eslint --fix"
]
} }
} }

8
pnpm-lock.yaml generated
View File

@ -117,6 +117,9 @@ importers:
'@repo/eslint-config': '@repo/eslint-config':
specifier: workspace:* specifier: workspace:*
version: link:../../packages/eslint-config version: link:../../packages/eslint-config
'@repo/lint-staged-config':
specifier: workspace:*
version: link:../../packages/lint-staged-config
'@repo/typescript-config': '@repo/typescript-config':
specifier: workspace:* specifier: workspace:*
version: link:../../packages/typescript-config version: link:../../packages/typescript-config
@ -160,6 +163,8 @@ importers:
specifier: 'catalog:' specifier: 'catalog:'
version: 2.3.2(eslint@9.15.0(jiti@1.21.6)) version: 2.3.2(eslint@9.15.0(jiti@1.21.6))
packages/lint-staged-config: {}
packages/typescript-config: {} packages/typescript-config: {}
packages/ui: packages/ui:
@ -177,6 +182,9 @@ importers:
'@repo/eslint-config': '@repo/eslint-config':
specifier: workspace:* specifier: workspace:*
version: link:../eslint-config version: link:../eslint-config
'@repo/lint-staged-config':
specifier: workspace:*
version: link:../lint-staged-config
'@repo/typescript-config': '@repo/typescript-config':
specifier: workspace:* specifier: workspace:*
version: link:../typescript-config version: link:../typescript-config