Style: Enable import/no-extraneous-dependencies rule (#12374)

This commit is contained in:
fisker Cheung authored and GitHub committed 2022-02-28 19:25:02 +08:00
1 parent af103ae766
commit 23c173b9e4
2 files changed
+7 -7

No files matched your search

+6 -7
View File
@@ -104,13 +104,12 @@ module.exports = {
], ],
"import/extensions": ["error", "ignorePackages"], "import/extensions": ["error", "ignorePackages"],
// TODO[@fisker]: Fix this "import/no-extraneous-dependencies": [
// "import/no-extraneous-dependencies": [ "error",
// "error", {
// { devDependencies: ["jest.config.mjs", "tests/**", "scripts/**"],
// devDependencies: ["jest.config.mjs", "tests/**", "scripts/**"], },
// }, ],
// ],
"import/order": "error", "import/order": "error",
"import/no-anonymous-default-export": "error", "import/no-anonymous-default-export": "error",
+1
View File
@@ -169,6 +169,7 @@ async function format(context, input, opt) {
if (context.argv.debugBenchmark) { if (context.argv.debugBenchmark) {
let benchmark; let benchmark;
try { try {
// eslint-disable-next-line import/no-extraneous-dependencies
({ default: benchmark } = await import("benchmark")); ({ default: benchmark } = await import("benchmark"));
} catch { } catch {
context.logger.debug( context.logger.debug(