Skip to content
Merged
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
5 changes: 2 additions & 3 deletions api/.env → api/.env.example
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
PORT=3004
DB_NAME=irms
DB_PATH=/playtakdb
DB_PATH=../playtakdb
NODE_ENV=local
APP_ENV=Local
CORS_DOMAIN='*'
ANON_DB_PATH=/playtakdb/games_anon.db
ANON_DB_PATH=../playtakdb/games_anon.db
DIST_PATH=dist/
PREVIOUS_FILE=previous.txt
RATING_OUTPUT_PATH=dist/
Expand Down
36 changes: 0 additions & 36 deletions api/.eslintrc

This file was deleted.

30 changes: 0 additions & 30 deletions api/.eslintrc.js

This file was deleted.

5 changes: 3 additions & 2 deletions api/.prettierrc
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"singleQuote": true,
"trailingComma": "all",
"trailingComma": "none",
"useTabs": true,
"tabWidth": 4
"tabWidth": 4,
"printWidth": 120
}
2 changes: 1 addition & 1 deletion api/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:20-alpine3.21 AS development
FROM node:22-alpine3.21 AS development
WORKDIR /usr/src/app

# Copy package files
Expand Down
110 changes: 49 additions & 61 deletions api/eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,79 +1,67 @@
import typescriptEslintEslintPlugin from "@typescript-eslint/eslint-plugin";
import globals from "globals";
import tsParser from "@typescript-eslint/parser";
import path from "node:path";
import { fileURLToPath } from "node:url";
import js from "@eslint/js";
import { FlatCompat } from "@eslint/eslintrc";
import typescriptEslintPlugin from '@typescript-eslint/eslint-plugin';
import globals from 'globals';
import tsParser from '@typescript-eslint/parser';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import js from '@eslint/js';
import { FlatCompat } from '@eslint/eslintrc';

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all
allConfig: js.configs.all,
});

export default [{
ignores: ["**/.eslintrc.js"],
}, ...compat.extends("plugin:@typescript-eslint/recommended"), {
plugins: {
"@typescript-eslint": typescriptEslintEslintPlugin,
export default [
{
ignores: ['**/eslint.config.mjs'],
},

languageOptions: {
globals: {
...globals.node,
...globals.jest,
...compat.extends(
'plugin:@typescript-eslint/recommended',
'plugin:prettier/recommended',
),
{
plugins: {
'@typescript-eslint': typescriptEslintPlugin,
},

parser: tsParser,
ecmaVersion: 5,
sourceType: "module",
languageOptions: {
globals: {
...globals.node,
...globals.jest,
},

parserOptions: {
project: "tsconfig.json",
tsconfigRootDir: "./",
},
},
parser: tsParser,
ecmaVersion: 5,
sourceType: 'module',

rules: {
"@typescript-eslint/interface-name-prefix": "off",
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/explicit-module-boundary-types": "off",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-unused-expressions": "off",
"eol-last": "off",
"brace-style": "off",
"comma-dangle": "off",
"comma-spacing": "off",
eqeqeq: "off",
indent: "off",
"key-spacing": "off",
"keyword-spacing": "off",
"max-len": "off",
"no-ex-assign": "off",
"no-extra-boolean-cast": "off",
"no-floating-decimal": "off",
"no-multi-spaces": "off",
"no-throw-literal": "off",
"no-unreachable": "off",
radix: "off",
"quote-props": "off",
quotes: "off",
"space-before-function-paren": "off",
"space-in-parens": "off",
"space-infix-ops": "off",
"space-unary-ops": "off",
"spaced-comment": "off",
indent: ["warn", "tab", {
SwitchCase: 1,
parserOptions: {
project: path.resolve(__dirname, 'tsconfig.json'),
},
},

ignoredNodes: [
"FunctionExpression > .params[decorators.length > 0]",
rules: {
'@typescript-eslint/interface-name-prefix': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
indent: [
'error',
'tab',
{
SwitchCase: 1,
flatTernaryExpressions: false,
ignoredNodes: [
'FunctionExpression[params]:has(Identifier[decorators])',
"FunctionExpression > .params[decorators.length > 0]",
"FunctionExpression > .params > :matches(Decorator, :not(:first-child))",
"ClassBody.body > PropertyDefinition[decorators.length > 0] > .key",
],
},
],
}],
'comma-dangle': 'off',
},
},
}];
];
Loading