Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 0 additions & 35 deletions .eslintrc.js

This file was deleted.

1 change: 1 addition & 0 deletions defi-monitor
Submodule defi-monitor added at 92b2fe
71 changes: 71 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
// @ts-check
import eslint from '@eslint/js';
import tseslint from 'typescript-eslint';
import prettier from 'eslint-plugin-prettier/recommended';

export default tseslint.config(
// Base ESLint recommended rules
eslint.configs.recommended,

// TypeScript ESLint recommended rules
...tseslint.configs.recommended,
...tseslint.configs.recommendedTypeChecked,

// Prettier integration
prettier,

// Global ignores
{
ignores: [
'lib/**',
'client/**',
'utils/**',
'node_modules/**',
'dist/**',
'*.js',
'*.mjs',
'migrations/**',
],
},

// TypeScript files configuration
{
files: ['src/**/*.ts', 'tests/**/*.ts'],
languageOptions: {
parserOptions: {
projectService: true,
tsconfigRootDir: import.meta.dirname,
},
},
rules: {
// Prettier
'prettier/prettier': 'error',

// TypeScript rules
'@typescript-eslint/no-inferrable-types': 'off',
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-use-before-define': ['error', { functions: false }],
'@typescript-eslint/no-floating-promises': ['error', { ignoreVoid: true }],

// Warnings
'no-warning-comments': 'warn',

// TODO: fix these - temporarily disabled for migration
'@typescript-eslint/no-unsafe-assignment': 'off',
'@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/no-unsafe-call': 'off',
'@typescript-eslint/restrict-template-expressions': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/restrict-plus-operands': 'off',
'@typescript-eslint/no-misused-promises': 'off',
'@typescript-eslint/no-unsafe-argument': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': ['warn', { argsIgnorePattern: '^_' }],
'@typescript-eslint/no-require-imports': 'off',

// Allow console in this project
'no-console': 'off',
},
},
);

14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@
"start": "node ./lib/index.js",
"lint": "npm run lint:eslint && npm run lint:prettier",
"lint:unused-exports": "ts-unused-exports tsconfig.json --showLineNumber",
"lint:eslint": "eslint . --ext .js,.jsx,.ts,.tsx -f unix",
"lint:eslint": "eslint src tests --format unix",
"lint:prettier": "prettier --check src/**/*.{ts,json}",
"lint:fix": "eslint . --ext .js,.jsx,.ts,.tsx -f unix --fix && prettier --write --check src/**/*.{ts,json}",
"lint:fix": "eslint src tests --format unix --fix && prettier --write --check src/**/*.{ts,json}",
"migrate": "node-pg-migrate -m migrations",
"devenv:build": "docker compose -f docker/docker-compose.dev.postgres.yml -f docker/docker-compose.dev.stacks-blockchain.yml -f docker/docker-compose.dev.bitcoind.yml -f docker/docker-compose.dev.rosetta-cli.yml build --no-cache",
"devenv:deploy": "docker compose -f docker/docker-compose.dev.postgres.yml -f docker/docker-compose.dev.stacks-blockchain.yml -f docker/docker-compose.dev.bitcoind.yml up --force-recreate -V",
Expand Down Expand Up @@ -180,14 +180,14 @@
"@types/supertest": "2.0.11",
"@types/tiny-secp256k1": "2.0.1",
"@types/uuid": "7.0.5",
"@typescript-eslint/eslint-plugin": "5.46.1",
"@typescript-eslint/parser": "5.51.0",
"@eslint/js": "^9.17.0",
"typescript-eslint": "^8.18.1",
"concurrently": "7.3.0",
"docker-compose": "0.24.8",
"dockerode": "4.0.6",
"eslint": "8.29.0",
"eslint-plugin-prettier": "4.2.1",
"eslint-plugin-tsdoc": "0.2.17",
"eslint": "^9.17.0",
"eslint-plugin-prettier": "^5.2.1",
"eslint-config-prettier": "^9.1.0",
"husky": "4.3.8",
"is-ci": "3.0.1",
"jest": "29.7.0",
Expand Down
Loading