2026-09-04 12:21:06 +02:00
|
|
|
// ESLint 9 (niet 10): eslint-plugin-react ondersteunt nog geen ESLint 10
|
|
|
|
|
// (peer: eslint <= ^9.7). Zodra de plugin bijtrekt kan dit mee omhoog.
|
|
|
|
|
import js from "@eslint/js";
|
|
|
|
|
import react from "eslint-plugin-react";
|
|
|
|
|
import globals from "globals";
|
|
|
|
|
|
|
|
|
|
export default [
|
|
|
|
|
js.configs.recommended,
|
|
|
|
|
react.configs.flat.recommended,
|
|
|
|
|
react.configs.flat["jsx-runtime"],
|
|
|
|
|
{
|
|
|
|
|
files: ["src/**/*.{js,jsx}"],
|
|
|
|
|
languageOptions: {
|
|
|
|
|
ecmaVersion: "latest",
|
|
|
|
|
sourceType: "module",
|
2026-09-09 12:43:11 +02:00
|
|
|
// Door Vite ingebakken tijdens de build (define in vite.config.js)
|
|
|
|
|
globals: { ...globals.browser, __APP_VERSION__: "readonly" },
|
2026-09-04 12:21:06 +02:00
|
|
|
parserOptions: { ecmaFeatures: { jsx: true } },
|
|
|
|
|
},
|
|
|
|
|
settings: { react: { version: "detect" } },
|
|
|
|
|
rules: {
|
|
|
|
|
"no-unused-vars": ["warn", { argsIgnorePattern: "^_" }],
|
|
|
|
|
"react/prop-types": "off",
|
|
|
|
|
// Lege catch-blokken zijn hier bewust (localStorage kan gooien)
|
|
|
|
|
"no-empty": ["error", { allowEmptyCatch: true }],
|
|
|
|
|
// De icoon-arrays worden per index gerenderd, niet als lijst; geen
|
|
|
|
|
// runtime-waarschuwing van React, dus een hint in plaats van een fout.
|
|
|
|
|
"react/jsx-key": "warn",
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
];
|