Skip to content

Commit 81e601e

Browse files
committed
Oppgraderte pakker
Fjernet eslint-config-teamia.
1 parent 8b152cb commit 81e601e

File tree

5 files changed

+2004
-2090
lines changed

5 files changed

+2004
-2090
lines changed

.eslintignore

-2
This file was deleted.

eslint.config.mjs

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
import { fixupConfigRules } from "@eslint/compat";
2+
import { FlatCompat } from '@eslint/eslintrc';
3+
import js from "@eslint/js";
4+
const compat = new FlatCompat({
5+
baseDirectory: import.meta.dirname,
6+
recommendedConfig: js.configs.recommended
7+
})
8+
9+
const eslingconfig = [
10+
...compat.config(
11+
...fixupConfigRules(
12+
{
13+
extends: [
14+
"eslint:recommended",
15+
"plugin:@typescript-eslint/eslint-recommended",
16+
"plugin:@typescript-eslint/recommended",
17+
"plugin:jest/recommended",
18+
"next/core-web-vitals",
19+
"prettier", // Add "prettier" last. This will turn off eslint rules conflicting with prettier. This is not what will format our code.
20+
],
21+
rules: {
22+
"@typescript-eslint/no-unused-vars": "error",
23+
"@typescript-eslint/no-empty-function": "off",
24+
"@typescript-eslint/ban-ts-comment": "off",
25+
"jsx-a11y/anchor-ambiguous-text": [
26+
2,
27+
{
28+
words: [
29+
"her",
30+
"klikk",
31+
"klikk her",
32+
"trykk",
33+
"trykk her",
34+
"lenken",
35+
"linken",
36+
"lenka",
37+
"lenken her",
38+
"linken her",
39+
"lenka her",
40+
"denne lenken",
41+
"denne linken",
42+
"denne lenka",
43+
],
44+
},
45+
],
46+
},
47+
settings: {},
48+
ignorePatterns: ["*.module.css", "*.{config,setup}.{ts,js}", "dist/*", "node_modules/*"],
49+
}
50+
),
51+
)
52+
];
53+
54+
export default eslingconfig;

package.json

+22-18
Original file line numberDiff line numberDiff line change
@@ -13,20 +13,16 @@
1313
"watch": "jest --watch",
1414
"export": "next export"
1515
},
16-
"eslintConfig": {
17-
"extends": [
18-
"@navikt/eslint-config-teamia"
19-
]
20-
},
16+
"prettier": {},
2117
"dependencies": {
22-
"@amplitude/analytics-browser": "^2.11.12",
23-
"@grafana/faro-web-sdk": "^1.14.0",
24-
"@navikt/aksel-icons": "^7.14.2",
18+
"@amplitude/analytics-browser": "^2.11.13",
19+
"@grafana/faro-web-sdk": "^1.14.1",
20+
"@navikt/aksel-icons": "^7.17.1",
2521
"@navikt/arbeidsgiver-notifikasjon-widget": "^7.2.3",
2622
"@navikt/bedriftsmeny": "^7.0.5",
27-
"@navikt/ds-css": "^7.14.2",
23+
"@navikt/ds-css": "^7.17.1",
2824
"@navikt/ds-icons": "^3.4.3",
29-
"@navikt/ds-react": "^7.14.2",
25+
"@navikt/ds-react": "^7.17.1",
3026
"@navikt/ia-metrikker-client": "1.9.4",
3127
"@navikt/nav-dekoratoren-moduler": "^2.1.6",
3228
"@navikt/next-api-proxy": "^4.1.3",
@@ -39,35 +35,43 @@
3935
"@types/uuid": "^10.0.0",
4036
"dotenv": "^16.4.7",
4137
"msw": "2.7.3",
42-
"next": "15.2.0",
38+
"next": "15.2.2",
4339
"pino": "^9.6.0",
4440
"react": "^19.0.0",
4541
"react-dom": "^19.0.0",
46-
"react-router-dom": "^6.29.0",
42+
"react-router-dom": "^7.3.0",
4743
"react-to-print": "^3.0.5",
4844
"recharts": "^2.15.1",
49-
"swr": "^2.3.2",
45+
"swr": "^2.3.3",
5046
"typescript": "^5.7.3",
5147
"uuid": "^11.1.0",
5248
"zod": "^3.24.2"
5349
},
5450
"devDependencies": {
55-
"@navikt/eslint-config-teamia": "^1.0.8",
51+
"@eslint/compat": "^1.2.7",
52+
"@eslint/js": "^10.0.0",
5653
"@testing-library/jest-dom": "^6.6.3",
5754
"@testing-library/react": "^16.2.0",
5855
"@testing-library/user-event": "^14.6.1",
5956
"@types/jest": "^29.5.14",
6057
"@types/jest-axe": "^3.5.9",
61-
"@types/node": "^22.13.5",
58+
"@types/node": "^22.13.10",
6259
"@types/react": "19.0.10",
6360
"@types/react-dom": "19.0.4",
64-
"core-js": "^3.40.0",
65-
"jest-axe": "^9.0.0",
61+
"core-js": "^3.41.0",
62+
"eslint": "^9.22.0",
63+
"eslint-config-next": "^15.2.2",
64+
"eslint-config-prettier": "^10.1.1",
65+
"eslint-plugin-jest": "^28.11.0",
66+
"eslint-plugin-next": "^0.0.0",
67+
"jest": "^29.7.0",
68+
"jest-axe": "^10.0.0",
6669
"jest-cli": "^29.7.0",
6770
"jest-environment-jsdom": "^29.7.0",
6871
"jest-transform-stub": "^2.0.0",
69-
"prettier": "^3.5.2",
72+
"prettier": "^3.5.3",
7073
"sass": "^1.85.1",
74+
"typescript-eslint": "^8.26.1",
7175
"whatwg-fetch": "^3.6.20"
7276
}
7377
}

src/pages/api/logger.ts

+1
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ function isNonEmptyStringArray(message: unknown): message is NonEmptyStringArray
2929
try{
3030
z.string().array().min(1).parse(message)
3131
return true
32+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
3233
} catch (e) {
3334
return false
3435
}

0 commit comments

Comments
 (0)