Files
payload/test/tsconfig.json
Alessio Gravili 1038e1c228 chore: move to eslint v9 (#7041)
- Upgrades eslint from v8 to v9
- Upgrades all other eslint packages. We will have to do a new
full-project lint, as new rules have been added
- Upgrades husky from v8 to v9
- Upgrades lint-staged from v14 to v15
- Moves the old .eslintrc.cjs file format to the new eslint.config.js
flat file format.

Previously, we were very specific regarding which rules are applied to
which files. Now that `extends` is no longer a thing, I have to use
deepMerge & imports instead.

This is rather uncommon and is not a documented pattern - e.g.
typescript-eslint docs want us to add the default typescript-eslint
rules to the top-level & then disable it in files using the
disable-typechecked config.

However, I hate this opt-out approach. The way I did it here adds a lot
of clarity as to which rules are applied to which files, and is pretty
easy to read. Much less black magic

## .eslintignore

These files are no longer supported (see
https://eslint.org/docs/latest/use/configure/migration-guide#ignoring-files).
I moved the entries to the ignores property in the eslint config. => one
less file in each package folder!
2024-07-09 09:50:37 -04:00

50 lines
1.3 KiB
JSON

{
"compilerOptions": {
"noEmit": true,
"rootDir": ".",
"declaration": true,
"declarationMap": true,
"target": "esnext",
"module": "NodeNext",
"moduleResolution": "NodeNext",
"allowJs": true,
"checkJs": false,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"jsx": "preserve",
"lib": ["dom", "dom.iterable", "esnext"],
"resolveJsonModule": true,
"skipLibCheck": true,
"sourceMap": true,
"strict": false,
"types": ["jest", "node", "@types/jest"],
"incremental": true,
"isolatedModules": true,
"plugins": [
{
"name": "next"
}
],
"baseUrl": ".",
"paths": {
"@payloadcms/ui": [
"../packages/ui/src/exports/client/index.ts"
],
"@payloadcms/ui/shared": [
"../packages/ui/src/exports/shared/index.ts"
],
"@payloadcms/ui/scss": [
"../packages/ui/src/scss.scss"
],
"@payloadcms/ui/scss/app.scss": [
"../packages/ui/src/scss/app.scss"
],
"@payloadcms/next/*": ["./packages/next/src/exports/*.ts"],
"@payload-config": ["./_community/config.ts"]
}
},
"exclude": ["dist", "build", "node_modules", "eslint.config.js", "dist/**/*.js", "**/dist/**/*.js"],
"include": ["./**/*.ts", ".next/types/**/*.ts", "setup.js"],
"references": []
}