New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Library is broken with Typescript v5.2 #64
Comments
Also got an error on
Appears to happen on TS 5.2 and 5.3 |
I was doing a TS 5.2 upgrade today and saw this issue. However, I wasn't seeing any problem on TS 5.2 in my own project, which doesn't configure i.e. all I do in
Curious what the repro steps are for an issue? For example, do I need code that breaks a certain rule, or a certain rule enabled, to see an issue? I am on version |
Can you share the full configuration? Because of course, if you not enabling ANY eslint-plugin-etc rules, you are not gonna see any errors. |
You may have missed my edit above, I have since added my config :) |
I mean the whole file. |
I use lots of lint configs, so I won't post the whole thing, but the only other relevant part of the file (to
Otherwise, the but maybe that's not how it works 🤔 |
Ah, right, I forgot, that is indeed not how it works. I don't have
so i guess I'll amend my previous statement: It seems like this one rule |
I have the same issue of #64 (comment) type AnyObject = Record<string, unknown>;
// HERE IS THE LINE THAT BREAK
function pick<T extends AnyObject, K extends keyof T>(
obj: T,
keys: Array<K>
): Pick<T, K> {
const picked: Partial<Pick<T, K>> = {};
for (const key of keys) {
if (key in obj) {
picked[key] = obj[key];
}
}
return picked as Pick<T, K>;
} and the rule that breaks is |
I've taken a look at this. Fixing this is not straightforward, as the error is being effected from a dep that's pretty deep down: A lot of these lint rules rely on |
From the comments on your linked issue it actually seems like this |
Thanks for reading that issue's comments more thoroughly than I did, @Jelmerro. I'll take a look at |
Any news on this? 😉 |
With Typescript v5.2 using ESlint with this plugin throws an exception:
TypeError: DeprecationError: 'originalKeywordKind' has been deprecated since v5.0.0 and can no longer be used. Use 'identifierToKeywordKind(identifier)' instead.
The text was updated successfully, but these errors were encountered: