fix: Eslint jison linting

This commit is contained in:
Sidharth Vinod 2024-06-29 16:31:19 +05:30
parent 4c6e2783b0
commit 195e314c42
No known key found for this signature in database
GPG Key ID: FB5CCD378D3907CD
4 changed files with 4 additions and 17 deletions

View File

@ -69,8 +69,6 @@
"@eslint/js": "^9.4.0",
"@rollup/plugin-typescript": "^11.1.6",
"@types/cors": "^2.8.17",
"@types/eslint": "^8.56.10",
"@types/eslint__js": "^8.42.3",
"@types/express": "^4.17.21",
"@types/js-yaml": "^4.0.9",
"@types/jsdom": "^21.1.6",

View File

@ -1,3 +1,4 @@
/* eslint-disable */
/**
* This file was automatically generated by json-schema-to-typescript.
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,

13
pnpm-lock.yaml generated
View File

@ -29,12 +29,6 @@ importers:
'@types/cors':
specifier: ^2.8.17
version: 2.8.17
'@types/eslint':
specifier: ^8.56.10
version: 8.56.10
'@types/eslint__js':
specifier: ^8.42.3
version: 8.42.3
'@types/express':
specifier: ^4.17.21
version: 4.17.21
@ -2850,9 +2844,6 @@ packages:
'@types/eslint@8.56.10':
resolution: {integrity: sha512-Shavhk87gCtY2fhXDctcfS3e6FdxWkCx1iUZ9eEUbh7rTqlZT0/IzOkCOVt0fCjcFuZ9FPYfuezTBImfHCDBGQ==}
'@types/eslint__js@8.42.3':
resolution: {integrity: sha512-alfG737uhmPdnvkrLdZLcEKJ/B8s9Y4hrZ+YAdzUeoArBlSUERA2E87ROfOaS4jd/C45fzOoZzidLc1IPwLqOw==}
'@types/estree@0.0.39':
resolution: {integrity: sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==}
@ -11920,10 +11911,6 @@ snapshots:
'@types/estree': 1.0.5
'@types/json-schema': 7.0.15
'@types/eslint__js@8.42.3':
dependencies:
'@types/eslint': 8.56.10
'@types/estree@0.0.39': {}
'@types/estree@1.0.5': {}

View File

@ -6,8 +6,9 @@ import { ESLint } from 'eslint';
import jison from 'jison';
const linter = new ESLint({
overrideConfig: { rules: { 'no-console': 'error' }, parser: '@typescript-eslint/parser' },
useEslintrc: false,
// @ts-expect-error ESLint types are incorrect
overrideConfigFile: true,
overrideConfig: { rules: { 'no-console': 'error' } },
});
const lint = async (file: string): Promise<boolean> => {