-
-
Notifications
You must be signed in to change notification settings - Fork 26
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
Many rule allow unwanted additionalProperties #189
Comments
Oh nice there is a property for that? wow? This could actually fix all our issues 🎉 |
I will check that tomorrow or you already did a PR |
I didnt |
I meant: I will do a PR on my own tomorrow if you did not already send a PR from your side sorry for misunderstandment 😅 |
Other things that coiuld be fixed are ignore?: (string & { // string:not(...):not(...), should be just string here
[k: string]: any;
} & {
[k: string]: any;
})[]; and ignorePatterns?: any[]; // mostly string[] and maybe a couple of annoying TS types that depend on ESLint types |
In my language "I will check that tomorrow or you already did a PR" would be read as a question, so I answered that 😅 |
Some context-sensitive types like export type regex = string & { _?: regex }; // string that is used as RegExp pattern
export type glob = string & { _?: regex }; // string which is used as glob pattern could also be (very) useful, but that's hard to mantain |
I tried to configure So I think we will just use patching again |
@Dimava The Only stuff like But for now I fixed it with #190 |
plugin types are now supported via @eslint-type/* |
I see over 25 rules with
which disappear if
json-schema-to-typescript
is configured with{ additionalProperties: /* default to: */ false }
I think at least 75% of that is schema typos, and we should use
{ additionalProperties: /* default to: */ false }
If the type actually has additionalProperties it is always written in type (as
Record
types obviously require them to exist), while when it hasn't it may be just be forgottenThe text was updated successfully, but these errors were encountered: