Skip to content

Commit

Permalink
feat(resume): refine config files
Browse files Browse the repository at this point in the history
  • Loading branch information
hankliu62 committed May 17, 2024
1 parent 1777d1d commit 58ad809
Show file tree
Hide file tree
Showing 7 changed files with 1,750 additions and 555 deletions.
103 changes: 0 additions & 103 deletions .eslintrc.json

This file was deleted.

6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,8 @@ next-env.d.ts

.vscode

dist
dist

pnpm-lock.yaml
yarn.lock
package-lock.json
13 changes: 5 additions & 8 deletions .stylelintrc.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,15 @@
const fabric = require('@hankliu/fabric');

module.exports = {
processors: [],
plugins: [],
extends: [
"stylelint-config-standard",
"stylelint-order",
"stylelint-config-recess-order",
],
...fabric.stylelint,
rules: {
...fabric.stylelint.rules,
"at-rule-no-unknown": [
true,
{
ignoreAtRules: ["tailwind"],
},
],
"import-notation": "off",
"keyframes-name-pattern": null,
}, // 可以自己自定一些规则
};
14 changes: 14 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
const fabric = require('@hankliu/fabric');

module.exports = [
{
...fabric.eslint,
files: ['src/**/*.ts', 'src/**/*.tsx', 'src/**/*.js'],
},
{
ignores: ['public/*', 'out/*', 'docs/*'],
rules: {
'@typescript-eslint/no-unused-expressions': 'off',
},
},
];
9 changes: 7 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,19 @@
"build": "yarn build:less && next build",
"build:local": "yarn build:less && cross-env GITHUB_ACTIONS=true GITHUB_REPOSITORY='hankliu62/resume' next build",
"start": "next start",
"lint": "next lint",
"eslint": "eslint src",
"stylelint": "stylelint src/**/*.{css,less,scss}",
"lint": "npm run eslint && npm run stylelint",
"export": "next export",
"lint:fix": "eslint src --fix",
"prettier": "prettier --write \"./src/**/*.{ts,tsx,js,jsx,json,md}\"",
"prepare": "husky install"
},
"dependencies": {
"@ant-design/cssinjs": "^1.19.1",
"@ant-design/icons": "^5.3.6",
"@hankliu/fabric": "^0.0.1",
"@hankliu/rc-fullpage": "^0.0.2",
"@tailwindcss/forms": "^0.5.7",
"@types/node": "20.12.5",
"@types/react": "18.2.74",
Expand All @@ -36,7 +42,6 @@
"rc-tween-one": "^3.0.6",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-fullpage": "^0.1.19",
"react-svg": "^16.1.34",
"sass": "^1.74.1",
"swiper": "^11.1.0",
Expand Down
11 changes: 5 additions & 6 deletions prettier.config.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
const fabric = require('@hankliu/fabric');

module.exports = {
trailingComma: "es5",
tabWidth: 2,
semi: true,
singleQuote: false,
plugins: [require("prettier-plugin-tailwindcss")],
...fabric.prettier,
plugins: ["prettier-plugin-tailwindcss"],
tailwindConfig: "./tailwind.config.js",
};
};
Loading

0 comments on commit 58ad809

Please sign in to comment.