diff --git a/src/core-worker.ts b/src/core-worker.ts index 32ddb9b4..ac1df477 100644 --- a/src/core-worker.ts +++ b/src/core-worker.ts @@ -1,6 +1,7 @@ import { parentPort } from 'worker_threads'; import { expose } from 'comlink'; -import nodeEndpoint from 'comlink/dist/umd/node-adapter'; +// eslint-disable-next-line @typescript-eslint/no-require-imports +import nodeEndpoint = require('comlink/dist/umd/node-adapter'); import { ESLint } from 'eslint'; import { Core } from './core.js'; import { SuggestionFilter } from './transforms/apply-suggestions.js'; diff --git a/src/formatter/format-by-rules.ts b/src/formatter/format-by-rules.ts index cb7b6885..40c18e31 100644 --- a/src/formatter/format-by-rules.ts +++ b/src/formatter/format-by-rules.ts @@ -1,5 +1,6 @@ import chalk from 'chalk'; -import Table from 'cli-table'; +// eslint-disable-next-line @typescript-eslint/no-require-imports +import Table = require('cli-table'); import { ESLint } from 'eslint'; // import terminalLink from 'terminal-link'; import { ERROR_COLOR } from './colors.js'; diff --git a/src/index.ts b/src/index.ts index 3285be0b..d2fb732a 100755 --- a/src/index.ts +++ b/src/index.ts @@ -1,8 +1,10 @@ import { join } from 'path'; import { Worker } from 'worker_threads'; import { wrap } from 'comlink'; -import nodeEndpoint from 'comlink/dist/umd/node-adapter'; -import isInstalledGlobally from 'is-installed-globally'; +// eslint-disable-next-line @typescript-eslint/no-require-imports +import nodeEndpoint = require('comlink/dist/umd/node-adapter'); +// eslint-disable-next-line @typescript-eslint/no-require-imports +import isInstalledGlobally = require('is-installed-globally'); import { warn } from './cli/log.js'; import { parseArgv } from './cli/parse-argv.js'; import { SerializableCore } from './core-worker.js';