mirror of
https://github.com/UniversityOfHelsinkiCS/ohtuilmo.git
synced 2026-10-12 19:03:41 +03:00
chore: migrate to oxlint
This commit is contained in:
@@ -1,37 +0,0 @@
|
|||||||
module.exports = {
|
|
||||||
"env": {
|
|
||||||
"es6": true,
|
|
||||||
"node": true
|
|
||||||
},
|
|
||||||
"extends": "eslint:recommended",
|
|
||||||
"parserOptions": {
|
|
||||||
"ecmaVersion": 2018
|
|
||||||
},
|
|
||||||
"rules": {
|
|
||||||
"indent": [
|
|
||||||
"error",
|
|
||||||
2
|
|
||||||
],
|
|
||||||
"linebreak-style": [
|
|
||||||
"error",
|
|
||||||
"unix"
|
|
||||||
],
|
|
||||||
"quotes": [
|
|
||||||
"error",
|
|
||||||
"single"
|
|
||||||
],
|
|
||||||
"semi": [
|
|
||||||
"error",
|
|
||||||
"never"
|
|
||||||
],
|
|
||||||
"eqeqeq": "error",
|
|
||||||
"no-trailing-spaces": "error",
|
|
||||||
"object-curly-spacing": [
|
|
||||||
"error", "always"
|
|
||||||
],
|
|
||||||
"arrow-spacing": [
|
|
||||||
"error", { "before": true, "after": true }
|
|
||||||
],
|
|
||||||
"no-console" : 0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
{
|
||||||
|
"$schema": "./node_modules/oxlint/configuration_schema.json",
|
||||||
|
"plugins": [],
|
||||||
|
"categories": {
|
||||||
|
"correctness": "error"
|
||||||
|
},
|
||||||
|
"env": {
|
||||||
|
"builtin": true
|
||||||
|
},
|
||||||
|
"rules": {
|
||||||
|
"eqeqeq": "error"
|
||||||
|
}
|
||||||
|
}
|
||||||
Generated
+391
-1024
File diff suppressed because it is too large
Load Diff
@@ -12,8 +12,8 @@
|
|||||||
"test-setup": "docker compose -f ../compose.local-test.yaml --profile local-api up -d --force-recreate",
|
"test-setup": "docker compose -f ../compose.local-test.yaml --profile local-api up -d --force-recreate",
|
||||||
"test-setup:down": "docker compose -f ../compose.local-test.yaml --profile local-api down",
|
"test-setup:down": "docker compose -f ../compose.local-test.yaml --profile local-api down",
|
||||||
"test:docker": "docker compose -f ../compose.local-test.yaml down && docker compose -f ../compose.local-test.yaml --profile api up --exit-code-from api-test",
|
"test:docker": "docker compose -f ../compose.local-test.yaml down && docker compose -f ../compose.local-test.yaml --profile api up --exit-code-from api-test",
|
||||||
"lint": "eslint .",
|
"lint": "oxlint .",
|
||||||
"lint:fix": "eslint --fix .",
|
"lint:fix": "oxlint --fix .",
|
||||||
"db:create": "sequelize db:create",
|
"db:create": "sequelize db:create",
|
||||||
"db:drop": "sequelize db:drop",
|
"db:drop": "sequelize db:drop",
|
||||||
"db:migrate": "sequelize db:migrate",
|
"db:migrate": "sequelize db:migrate",
|
||||||
@@ -52,10 +52,10 @@
|
|||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"cross-env": "^5.2.0",
|
"cross-env": "^5.2.0",
|
||||||
"eslint": "^5.14.1",
|
|
||||||
"husky": "^1.2.0",
|
"husky": "^1.2.0",
|
||||||
"jest": "^30.2.0",
|
"jest": "^30.2.0",
|
||||||
"nodemon": "^1.18.7",
|
"nodemon": "^1.18.7",
|
||||||
|
"oxlint": "^1.77.0",
|
||||||
"supertest": "^7.1.4"
|
"supertest": "^7.1.4"
|
||||||
},
|
},
|
||||||
"husky": {
|
"husky": {
|
||||||
|
|||||||
@@ -1,3 +0,0 @@
|
|||||||
build
|
|
||||||
node_modules
|
|
||||||
public
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
module.exports = {
|
|
||||||
env: {
|
|
||||||
es6: true,
|
|
||||||
node: true,
|
|
||||||
browser: true,
|
|
||||||
},
|
|
||||||
extends: [
|
|
||||||
'eslint:recommended',
|
|
||||||
'plugin:react/recommended',
|
|
||||||
'plugin:react/jsx-runtime',
|
|
||||||
'plugin:react-hooks/recommended',
|
|
||||||
],
|
|
||||||
parserOptions: {
|
|
||||||
ecmaVersion: 'latest',
|
|
||||||
sourceType: 'module',
|
|
||||||
},
|
|
||||||
settings: { react: { version: '16.8' } },
|
|
||||||
plugins: ['react', 'react-refresh'],
|
|
||||||
rules: {
|
|
||||||
'react/jsx-uses-react': 'error',
|
|
||||||
'react/jsx-uses-vars': 'error',
|
|
||||||
indent: ['error', 2],
|
|
||||||
quotes: ['error', 'single'],
|
|
||||||
semi: ['error', 'never'],
|
|
||||||
eqeqeq: 'error',
|
|
||||||
'no-trailing-spaces': 'error',
|
|
||||||
'object-curly-spacing': ['error', 'always'],
|
|
||||||
'arrow-spacing': ['error', { before: true, after: true }],
|
|
||||||
'no-console': 0,
|
|
||||||
'react/prop-types': 0,
|
|
||||||
'no-unused-vars': 0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
{
|
||||||
|
"$schema": "./node_modules/oxlint/configuration_schema.json",
|
||||||
|
"ignorePatterns": ["build", "public"],
|
||||||
|
"plugins": ["react"],
|
||||||
|
"categories": {
|
||||||
|
"correctness": "error"
|
||||||
|
},
|
||||||
|
"env": {
|
||||||
|
"builtin": true
|
||||||
|
},
|
||||||
|
"settings": {
|
||||||
|
"react": {
|
||||||
|
"version": "16.8"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"rules": {
|
||||||
|
"eqeqeq": "error",
|
||||||
|
"react-hooks/exhaustive-deps": "warn"
|
||||||
|
}
|
||||||
|
}
|
||||||
Generated
+385
-2311
File diff suppressed because it is too large
Load Diff
@@ -31,18 +31,15 @@
|
|||||||
"test:docker:down": "docker compose -f ../compose.local-test.yaml --profile e2e down",
|
"test:docker:down": "docker compose -f ../compose.local-test.yaml --profile e2e down",
|
||||||
"test": "CYPRESS_baseUrl=http://localhost:5000 npx cypress open",
|
"test": "CYPRESS_baseUrl=http://localhost:5000 npx cypress open",
|
||||||
"test:headless": "CYPRESS_VIDEO=false CYPRESS_baseUrl=http://localhost:5000 npx cypress run",
|
"test:headless": "CYPRESS_VIDEO=false CYPRESS_baseUrl=http://localhost:5000 npx cypress run",
|
||||||
"lint": "eslint src/",
|
"lint": "oxlint src/",
|
||||||
"lint:fix": "eslint --fix src/"
|
"lint:fix": "oxlint --fix src/"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@vitejs/plugin-react": "^4.2.1",
|
"@vitejs/plugin-react": "^4.2.1",
|
||||||
"@vitejs/plugin-react-refresh": "^1.3.6",
|
"@vitejs/plugin-react-refresh": "^1.3.6",
|
||||||
"cypress": "^13.17.0",
|
"cypress": "^13.17.0",
|
||||||
"eslint": "^8.57.0",
|
|
||||||
"eslint-plugin-react": "^7.34.1",
|
|
||||||
"eslint-plugin-react-hooks": "^4.6.0",
|
|
||||||
"eslint-plugin-react-refresh": "^0.4.6",
|
|
||||||
"husky": "^1.2.0",
|
"husky": "^1.2.0",
|
||||||
|
"oxlint": "^1.77.0",
|
||||||
"vite": "^5.2.0"
|
"vite": "^5.2.0"
|
||||||
},
|
},
|
||||||
"husky": {
|
"husky": {
|
||||||
|
|||||||
Reference in New Issue
Block a user