File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,11 @@ type ClassicConfigs = Record<SupportedTestingFramework, Linter.LegacyConfig>;
1212type FlatConfigs = Record < `flat/${SupportedTestingFramework } `, Linter . Config > ;
1313type PluginConfigs = ClassicConfigs & FlatConfigs ;
1414
15+ type TestingLibraryPlugin = Omit < ESLint . Plugin , 'rules' | 'configs' > & {
16+ rules : NonNullable < ESLint . Plugin [ 'rules' ] > ;
17+ configs : PluginConfigs ;
18+ } ;
19+
1520const PLUGIN_NAME = 'testing-library' as const ;
1621
1722function createPluginFlatConfigs ( ) {
@@ -55,7 +60,7 @@ function createPluginLegacyConfigs() {
5560 } ;
5661}
5762
58- const testingLibraryPlugin : ESLint . Plugin = {
63+ const testingLibraryPlugin : TestingLibraryPlugin = {
5964 meta : {
6065 name : packageName ,
6166 version : packageVersion ,
@@ -64,7 +69,7 @@ const testingLibraryPlugin: ESLint.Plugin = {
6469 configs : {
6570 ...createPluginFlatConfigs ( ) ,
6671 ...createPluginLegacyConfigs ( ) ,
67- } satisfies PluginConfigs ,
72+ } ,
6873} ;
6974
7075export default testingLibraryPlugin ;
You can’t perform that action at this time.
0 commit comments