Merge pull request #186 from hamster1963/pr-dev

test: auto lint
This commit is contained in:
仓鼠 2024-12-13 15:40:48 +08:00 committed by GitHub
commit 406b7ef37f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 22 additions and 34 deletions

8
.eslintrc.json Normal file
View File

@ -0,0 +1,8 @@
{
"extends": ["next/core-web-vitals", "next/typescript"],
"rules": {
"@typescript-eslint/no-explicit-any": "off",
"@next/next/no-img-element": "off",
"react-hooks/exhaustive-deps": "off"
}
}

12
.prettierrc.json Normal file
View File

@ -0,0 +1,12 @@
{
"semi": false,
"singleQuote": false,
"printWidth": 100,
"tabWidth": 2,
"trailingComma": "all",
"importOrder": ["^@core/(.*)$", "^@server/(.*)$", "^@ui/(.*)$", "^[./]"],
"importOrderSeparation": true,
"importOrderSortSpecifiers": true,
"endOfLine": "auto",
"plugins": ["prettier-plugin-tailwindcss", "@trivago/prettier-plugin-sort-imports"]
}

View File

@ -1,12 +0,0 @@
export default {
semi: false,
singleQuote: false,
printWidth: 100,
tabWidth: 2,
trailingComma: "all",
importOrder: ["^@core/(.*)$", "^@server/(.*)$", "^@ui/(.*)$", "^[./]"],
importOrderSeparation: true,
importOrderSortSpecifiers: true,
endOfLine: "auto",
plugins: ["prettier-plugin-tailwindcss", "@trivago/prettier-plugin-sort-imports"],
}

BIN
bun.lockb

Binary file not shown.

View File

@ -1,20 +0,0 @@
import js from "@eslint/js"
import globals from "globals"
import tseslint from "typescript-eslint"
export default tseslint.config(
{ ignores: [".next"] },
{
extends: [js.configs.recommended, ...tseslint.configs.recommended,"next/core-web-vitals", "next/typescript"],
files: ["**/*.{ts,tsx}"],
languageOptions: {
ecmaVersion: 2020,
globals: globals.browser,
},
rules: {
"@typescript-eslint/no-explicit-any": "off",
"@next/next/no-img-element": "off",
"react-hooks/exhaustive-deps": "off",
},
},
)

View File

@ -5,8 +5,8 @@
"scripts": {
"dev": "next dev -p 3040",
"start": "node .next/standalone/server.js",
"lint": "eslint",
"lint:fix": "eslint --fix",
"lint": "next lint",
"lint:fix": "next lint --fix",
"format": "prettier --write .",
"build": "next build && cp -r .next/static .next/standalone/.next/ && cp -r public .next/standalone/",
"build-dev": "next build",