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] Update to nodejs v22 #1975

Merged
merged 22 commits into from
Nov 19, 2024
Merged

[Chore] Update to nodejs v22 #1975

merged 22 commits into from
Nov 19, 2024

Conversation

art-alexeyenko
Copy link
Contributor

@art-alexeyenko art-alexeyenko commented Nov 17, 2024

  • This PR follows the Contribution Guide
  • Changelog updated
  • Upgrade guide entry added - TBA

Description / Motivation

Update monorepo and samples to use node 22

  • Update engine to node>=22
  • Update @types/node deps to 22.9.0
  • Update typescript across the board to 5.6.3 for compatibility
    • This also required updates for @typescript-eslint
    • @typescript-eslint plugin updated to version 8, some rules adjusted
    • @stylistic/eslint-plugin-ts dep added to keep using rules removed from @typescript-eslint (💀 Rule deprecations: formatting rules typescript-eslint/typescript-eslint#8072)
    • eslint version has been bumped to 8 for compatibility. v9 introduces some breaking changes in configuration and will be upgraded to later
    • Code adjusted to newer lint rules
  • Updates to react, nextjs
  • create-sitecore-jss updates
    • upgraded sinon
    • adjusted tests to handle errors correctly for new sinon

Known issue:

  • (node:8860) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead. error will pop up in console when building packages or apps. This does not affect app execution, and is caused by dependencies of dependencies JSS uses. This error will go away in time, as dependencies are updates (i.e. for http-proxy-middleware Deprecation warnings when using node v22 chimurai/http-proxy-middleware#1058).

Testing Details

  • Unit Test Adjusted
  • Manual Test/Other (Please elaborate) - build, lint, test, run samples

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

@art-alexeyenko art-alexeyenko requested a review from a team November 17, 2024 17:52
Copy link
Contributor

@yavorsk yavorsk left a comment

Choose a reason for hiding this comment

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

Great work!
The changes seem reasonable to me, I also verified build, lint, unit tests on my machine.
The only thing that looks off to me is the @ts-expect-error statements. Maybe we should investigate this deeper in a separate ticket?

Copy link
Contributor

@illiakovalenko illiakovalenko left a comment

Choose a reason for hiding this comment

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

Great job on this update! 👍
Please, review my comments/questions below

@art-alexeyenko art-alexeyenko merged commit ba1b7ea into dev Nov 19, 2024
1 check passed
@art-alexeyenko art-alexeyenko deleted the chore/update-node-22 branch November 19, 2024 19:40
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.

3 participants