Skip to content

Commit

Permalink
feat: typescript-eslint@v8
Browse files Browse the repository at this point in the history
Co-authored-by: Rostislav Simonik <rostislav.simonik@technologystudio.sk>

BREAKING CHANGE:

@typescript-eslint/ban-types is replaced with
@typescript-eslint/no-unsafe-function-type and
@typescript-eslint/no-wrapper-object-types.
@typescript-eslint/no-var-requires is replaced with
@typescript-eslint/no-require-imports.
@typescript-eslint/no-loss-of-precision is replaced with
no-loss-of-precision.
`languageOptions.parserOptions.project:true` is replaced with
`languageOptions.parserOptions.projectService:true`.
  • Loading branch information
mightyiam committed Aug 24, 2024
1 parent 0a13200 commit dcabf55
Show file tree
Hide file tree
Showing 8 changed files with 159 additions and 247 deletions.
17 changes: 8 additions & 9 deletions eslint.config.cjs
Original file line number Diff line number Diff line change
@@ -1,20 +1,19 @@
const tseslint = require('typescript-eslint')

module.exports = [
// eslint-disable-next-line @typescript-eslint/no-require-imports
require('.'),
{
files: ['**/*.cjs', '**/*.js', '**/*.ts'],
linterOptions: {
reportUnusedDisableDirectives: 'error',
},
},
{
files: ['eslint.config.cjs'],
rules: {
...tseslint.configs.disableTypeChecked.rules,
'@typescript-eslint/no-var-requires': 'off',
languageOptions: {
parserOptions: {
projectService: {
allowDefaultProject: ['eslint.config.cjs', 'commitlint.config.js'],
defaultProject: './tsconfig.json',
},
},
},
languageOptions: { parserOptions: { project: false } },
},
{
ignores: ['lib/'],
Expand Down
Loading

0 comments on commit dcabf55

Please sign in to comment.