As part of converting eslint-plugin-jest to typescript, I found that there are no typings for the plugins side of eslint.
Is that something typescript-eslint would be interested in covering?
having a look into the attached PRs - I see you're looking for processor types?
Sure thing!
Essentially the things that exist in experimental-utils is what was in the DefinitelyTyped types.
We'd love to have types for any and all things eslint.
We'd love to have types for any and all things eslint.
Awesome!
having a look into the attached PRs
Woops sorry I was meant to link to that header specifically - the anchor tag seems to have gotten lost 馃槵
I see you're looking for processor types?
For now yes, but I'd love to have as much types as possible - the index.ts export is completely untyped :(
I'm happy to help try & provide these types - at the very least it'll serve as a strawman to encourage refinement.
I'll start w/ adding types for the object described in the "Processors in Plugins" section of that page.
Just going to put this here for when I look to do the typings:
dump of
preprocess args
[
"<file source>",
"C:\\Users\\G-Rath\\workspace\\projects-personal\\strongly-typed-event-emitter\\test\\src\\__snapshots__\\index.spec.ts.snap"
]
dump of
postprocess args
[
[
[
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 3,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 3,
"endColumn": 55
},
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 9,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 9,
"endColumn": 56
},
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 21,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 21,
"endColumn": 57
},
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 33,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 33,
"endColumn": 85
},
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 43,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 43,
"endColumn": 66
},
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 51,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 51,
"endColumn": 62
},
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 63,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 63,
"endColumn": 55
},
{
"ruleId": "jest/no-large-snapshots",
"severity": 2,
"message": "Expected Jest snapshot to be smaller than 50 lines but was 71 lines long",
"line": 75,
"column": 1,
"nodeType": "ExpressionStatement",
"messageId": "tooLongSnapshots",
"endLine": 146,
"endColumn": 3
},
{
"ruleId": "quotes",
"severity": 2,
"message": "Strings must use singlequote.",
"line": 75,
"column": 9,
"nodeType": "TemplateLiteral",
"endLine": 75,
"endColumn": 68
}
]
],
"C:\\Users\\G-Rath\\workspace\\projects-personal\\strongly-typed-event-emitter\\test\\src\\__snapshots__\\index.spec.ts.snap"
]
I believe this issue has been addressed through a mixture of enhancements to experimental-utils and updates to DefinitelyTyped, so closing for now
Most helpful comment
having a look into the attached PRs - I see you're looking for processor types?
Sure thing!
Essentially the things that exist in
experimental-utilsis what was in the DefinitelyTyped types.We'd love to have types for any and all things eslint.