07dfd7e840
Backend 958→0 errors, frontend 98→0 errors. Builds and tsc clean. Echte Fixes: - Auth: AuthenticatedUser/AuthenticatedRequest, JwtStrategy + alle 5 Controller von `@Request() req: any` auf typisierten Request umgestellt - Error-Handling: neuer getErrorMessage/Stack/Code/getResponseData-Helper; alle 50 `catch (err: any)`-Blöcke auf `unknown` + Helper umgestellt - 24 echte Bugs: require-await, require-imports→ES-Imports, useless-escape, misused-promises, tote Imports/Vars, leere catch-Blöcke kommentiert - document-pipeline: OCR-Ergebnis wird nicht gespeichert (als TODO markiert) Pragmatisch auf warn herabgestuft (untypisierte Paperless-NGX-API): no-unsafe-*, restrict-template-expressions, no-base-to-string, no-explicit-any (FE), react-refresh/only-export-components Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
38 lines
1.1 KiB
JavaScript
38 lines
1.1 KiB
JavaScript
import js from '@eslint/js'
|
|
import globals from 'globals'
|
|
import reactHooks from 'eslint-plugin-react-hooks'
|
|
import reactRefresh from 'eslint-plugin-react-refresh'
|
|
import tseslint from 'typescript-eslint'
|
|
import { defineConfig, globalIgnores } from 'eslint/config'
|
|
|
|
export default defineConfig([
|
|
globalIgnores(['dist']),
|
|
{
|
|
files: ['**/*.{ts,tsx}'],
|
|
extends: [
|
|
js.configs.recommended,
|
|
tseslint.configs.recommended,
|
|
reactHooks.configs.flat.recommended,
|
|
reactRefresh.configs.vite,
|
|
],
|
|
languageOptions: {
|
|
ecmaVersion: 2020,
|
|
globals: globals.browser,
|
|
},
|
|
rules: {
|
|
// any-getriebene Regel als Warnung (untypisierte Paperless-NGX-API-Daten)
|
|
'@typescript-eslint/no-explicit-any': 'warn',
|
|
// Fast-Refresh-Hinweise sind Dev-Komfort, kein Build-Blocker
|
|
'react-refresh/only-export-components': 'warn',
|
|
'@typescript-eslint/no-unused-vars': [
|
|
'error',
|
|
{
|
|
argsIgnorePattern: '^_',
|
|
varsIgnorePattern: '^_',
|
|
caughtErrors: 'none',
|
|
},
|
|
],
|
|
},
|
|
},
|
|
])
|