Skip to content

chore: update eslint, typescript and support xstate v6#1398

Open
Rajesh-Nagarajan-11 wants to merge 2 commits intolayer5io:masterfrom
Rajesh-Nagarajan-11:chore/bump-eslint10-eslintjs10-ts6
Open

chore: update eslint, typescript and support xstate v6#1398
Rajesh-Nagarajan-11 wants to merge 2 commits intolayer5io:masterfrom
Rajesh-Nagarajan-11:chore/bump-eslint10-eslintjs10-ts6

Conversation

@Rajesh-Nagarajan-11
Copy link
Copy Markdown
Member

Notes for Reviewers

This PR updates development dependencies and improves compatibility:

  • eslint: 9.39.4 → 10.1.0
  • @eslint/js: 9.39.4 → 10.0.1
  • typescript: 5.9.3 → 6.0.2
  • Extended xstate peer dependency support to include v6

Tests

  • Tested with Meshery Cloud UI
  • Tested with Meshery UI

Signed commits

  • Yes, I signed my commits.

…escript to 6.0.2 with lint config compatibility fixes

Signed-off-by: Rajesh-Nagarajan-11 <rajeshnagarajan36@gmail.com>
Signed-off-by: Rajesh-Nagarajan-11 <rajeshnagarajan36@gmail.com>
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates several project dependencies and removes ESLint suppression comments across various React components. However, several critical issues were identified, specifically the use of non-existent versions for ESLint (10.1.0), @eslint/js (10.0.1), and TypeScript (6.0.2). Additionally, the removal of React-specific ESLint plugins significantly weakens the project's linting capabilities, and the addition of @mui/system and rxjs appears to introduce unused dependencies.

I am having trouble creating individual review comments. Click here to see my feedback.

package.json (48)

critical

The version ^10.0.1 for @eslint/js is invalid as version 10 has not been released. This should match the major version of ESLint being used (currently 9.x).

    "@eslint/js": "^9.16.0",

package.json (63)

critical

ESLint version 10.1.0 does not exist in the public npm registry. The current stable major version is 9. Using an invalid version will break the dependency installation process.

    "eslint": "^9.16.0",

package.json (84)

critical

TypeScript version ^6.0.2 is invalid. The current stable version is in the 5.x range. Please use a valid version such as ^5.7.2.

    "typescript": "^5.7.2",

eslint.config.js (3-4)

high

Removing eslint-plugin-react and eslint-plugin-react-hooks significantly weakens the linting process for this React project. It is highly recommended to keep these plugins and update them to versions compatible with ESLint 9's flat config rather than removing them entirely. Without these, critical issues like hook dependency errors or incorrect hook ordering will go unnoticed during development.

tsconfig.json (12)

medium

The ignoreDeprecations value "6.0" refers to a non-existent TypeScript version. This should be set to a version that matches your current TypeScript installation (e.g., "5.0").

        "ignoreDeprecations": "5.0",

tsup.config.ts (11)

medium

The ignoreDeprecations value "6.0" is invalid as it refers to a non-existent TypeScript version. It should be updated to match the project's actual TypeScript version.

  dts: { compilerOptions: { ignoreDeprecations: "5.0" } },

package.json (117)

medium

@mui/system is added as a dependency but is not used in any of the files modified in this PR. Please remove it if it's not required by other parts of the application.

package.json (127)

medium

rxjs is added as a dependency but is not used in the modified files. If this was added by mistake, it should be removed to avoid unnecessary dependency bloat.

@Rajesh-Nagarajan-11
Copy link
Copy Markdown
Member Author

Code Review

This pull request updates several project dependencies and removes ESLint suppression comments across various React components. However, several critical issues were identified, specifically the use of non-existent versions for ESLint (10.1.0), @eslint/js (10.0.1), and TypeScript (6.0.2). Additionally, the removal of React-specific ESLint plugins significantly weakens the project's linting capabilities, and the addition of @mui/system and rxjs appears to introduce unused dependencies.

I am having trouble creating individual review comments. Click here to see my feedback.

package.json (48)

critical

The version ^10.0.1 for @eslint/js is invalid as version 10 has not been released. This should match the major version of ESLint being used (currently 9.x).

    "@eslint/js": "^9.16.0",

package.json (63)

critical

ESLint version 10.1.0 does not exist in the public npm registry. The current stable major version is 9. Using an invalid version will break the dependency installation process.

    "eslint": "^9.16.0",

package.json (84)

critical

TypeScript version ^6.0.2 is invalid. The current stable version is in the 5.x range. Please use a valid version such as ^5.7.2.

    "typescript": "^5.7.2",

eslint.config.js (3-4)

high

Removing eslint-plugin-react and eslint-plugin-react-hooks significantly weakens the linting process for this React project. It is highly recommended to keep these plugins and update them to versions compatible with ESLint 9's flat config rather than removing them entirely. Without these, critical issues like hook dependency errors or incorrect hook ordering will go unnoticed during development.

tsconfig.json (12)

medium

The ignoreDeprecations value "6.0" refers to a non-existent TypeScript version. This should be set to a version that matches your current TypeScript installation (e.g., "5.0").

        "ignoreDeprecations": "5.0",

tsup.config.ts (11)

medium

The ignoreDeprecations value "6.0" is invalid as it refers to a non-existent TypeScript version. It should be updated to match the project's actual TypeScript version.

  dts: { compilerOptions: { ignoreDeprecations: "5.0" } },

package.json (117)

medium

@mui/system is added as a dependency but is not used in any of the files modified in this PR. Please remove it if it's not required by other parts of the application.

package.json (127)

medium

rxjs is added as a dependency but is not used in the modified files. If this was added by mistake, it should be removed to avoid unnecessary dependency bloat.

These comments are outdated relative to the current npm ecosystem and this PR state

  • @eslint/js@^10.0.1 is valid (v10 is published).
  • typescript@^6.0.2 is valid (latest is 6.0.2).
  • ignoreDeprecations: "6.0" is intentional and required in this repo with TS 6 + ts-jest; using "5.0" fails tests.
  • eslint-plugin-react / eslint-plugin-react-hooks were removed because current stable releases do not support ESLint 10 peer deps, which causes install resolution failures.

@saurabhraghuvanshii
Copy link
Copy Markdown
Member

LGTM!!

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.

2 participants