From 85d93c356b7449152215144663450107d9752f8c Mon Sep 17 00:00:00 2001 From: Josh Goldberg Date: Mon, 21 Oct 2024 21:16:03 -0400 Subject: [PATCH] chore: switch from explicit-function-return-type to explicit-module-boundary-types internally --- eslint.config.mjs | 5 +---- .../tests/lib/useProgramFromProjectService.test.ts | 1 - packages/website-eslint/src/mock/path.js | 1 + packages/website/src/theme/prism-include-languages.js | 1 + packages/website/tools/typedoc-plugin-no-inherit-fork.mjs | 2 +- 5 files changed, 4 insertions(+), 6 deletions(-) diff --git a/eslint.config.mjs b/eslint.config.mjs index 1bffc7d200f3..b0c5cfadfd25 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -125,10 +125,7 @@ export default tseslint.config( 'error', { prefer: 'type-imports', disallowTypeAnnotations: true }, ], - '@typescript-eslint/explicit-function-return-type': [ - 'error', - { allowIIFEs: true }, - ], + '@typescript-eslint/explicit-module-boundary-types': 'error', '@typescript-eslint/no-explicit-any': 'error', 'no-constant-condition': 'off', '@typescript-eslint/no-unnecessary-condition': [ diff --git a/packages/typescript-estree/tests/lib/useProgramFromProjectService.test.ts b/packages/typescript-estree/tests/lib/useProgramFromProjectService.test.ts index 1b0ffd3ed40b..ef319255b766 100644 --- a/packages/typescript-estree/tests/lib/useProgramFromProjectService.test.ts +++ b/packages/typescript-estree/tests/lib/useProgramFromProjectService.test.ts @@ -1,4 +1,3 @@ -/* eslint-disable @typescript-eslint/explicit-function-return-type -- Fancy mocks */ import path from 'node:path'; import * as ts from 'typescript'; diff --git a/packages/website-eslint/src/mock/path.js b/packages/website-eslint/src/mock/path.js index 5a097d8950de..bb6b9f3cba62 100644 --- a/packages/website-eslint/src/mock/path.js +++ b/packages/website-eslint/src/mock/path.js @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/explicit-module-boundary-types */ // Copyright Joyent, Inc. and other Node contributors. // // Permission is hereby granted, free of charge, to any person obtaining a diff --git a/packages/website/src/theme/prism-include-languages.js b/packages/website/src/theme/prism-include-languages.js index f356adf2a581..d4373970878d 100644 --- a/packages/website/src/theme/prism-include-languages.js +++ b/packages/website/src/theme/prism-include-languages.js @@ -1,3 +1,4 @@ +/* eslint-disable @typescript-eslint/explicit-module-boundary-types */ import siteConfig from '@generated/docusaurus.config'; export default function prismIncludeLanguages(PrismObject) { diff --git a/packages/website/tools/typedoc-plugin-no-inherit-fork.mjs b/packages/website/tools/typedoc-plugin-no-inherit-fork.mjs index 663c84d5b562..29daac327db7 100644 --- a/packages/website/tools/typedoc-plugin-no-inherit-fork.mjs +++ b/packages/website/tools/typedoc-plugin-no-inherit-fork.mjs @@ -1,4 +1,4 @@ -/* eslint-disable @typescript-eslint/explicit-function-return-type, @typescript-eslint/no-unnecessary-condition, @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/restrict-plus-operands */ +/* eslint-disable @typescript-eslint/explicit-module-boundary-types, @typescript-eslint/no-unnecessary-condition, @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/restrict-plus-operands */ // Internal fork of https://github.com/jonchardy/typedoc-plugin-no-inherit, // pending https://github.com/jonchardy/typedoc-plugin-no-inherit/issues/34 // https://github.com/jonchardy/typedoc-plugin-no-inherit/tree/c799761733e31198107db87d33aea0e673a996c3