Skip to content
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

chore(deps): updated typescript-eslint #1425

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

Danil42Russia
Copy link
Contributor

@Danil42Russia Danil42Russia commented Jan 20, 2025

Issue

Closes #1430.

There will likely be errors on CI that I couldn't catch locally, I'll fix them. Also maybe some of my solutions to errors are not suitable for you, I am ready to fix them.

Checklist

  • I have updated CHANGELOG.md
  • I have run all the tests locally and no test failure was reported
  • I have run the linter, formatter and spellchecker
  • I did not do unrelated and/or undiscussed refactorings

@Danil42Russia Danil42Russia requested a review from a team as a code owner January 20, 2025 19:06
@@ -375,6 +375,7 @@ const parseParens = ({ child }: $ast.Parens): Handler<A.AstExpression> => {
};

// has to be an interface because of the way TS handles circular type references
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
interface Binary extends $ast.Binary<Expression, A.AstBinaryOperation> {}
Copy link
Contributor Author

@Danil42Russia Danil42Russia Jan 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's the error I couldn't beat. As a temporary solution, I suppressed it

Copy link
Contributor

@verytactical verytactical Jan 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's completely fine to ignore it here, and you did the right thing.

This "empty" type is a workaround for a buggy implementation of recursive types in TS, and linter has no way to know about it.

: never
: never;
type Inputs<I, T extends string> =
I extends Record<T, infer K>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be checked manually. In TS a type and alias to the same type are not the same thing, because they implement aliases as instantations, in C++ way.

I'd rather prefer to disable that rule, because it's mostly pointless.

@@ -6,7 +6,7 @@
"target": "esnext" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', 'ES2021', or 'ESNEXT'. */,
"module": "commonjs" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */,
"lib": ["ESNext"],
// "allowJs": true, /* Allow javascript files to be compiled. */
"allowJs": true /* Allow javascript files to be compiled. */,
Copy link
Contributor

@verytactical verytactical Jan 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need this? Tact is TS-only project, and allowJs: false seems to be some kind of a lint.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update typescript-eslint
2 participants