Skip to content

chore(deps)!: compile with typescript 7 and support node 26 - #172

Merged
rohit-sourcefuse merged 1 commit into
masterfrom
GH-171
Dec 3, 2026
Merged

rohit-sourcefuse merged 1 commit into
masterfrom
GH-171

Conversation

@piyushsinghgaur1

Copy link
Copy Markdown
Contributor

Description

Fixes #171

This compiles the package with the TypeScript 7 native compiler and adds Node.js 26 to the supported engines and the CI matrix.

The runtime stays on LoopBack 7. The LoopBack 8 packages still peer on @loopback/core ^7, so moving now would nest a second LoopBack copy in every LoopBack 7 app. The LoopBack 8 move comes in a separate release.

BREAKING CHANGE: Yes

Consumers see two changes. engines now includes Node.js 26, and the package is built with TypeScript 7. The published declaration files stay usable from TypeScript 5.9 consumers.

What changes:

  • Dev tooling moves to @loopback/build 13, @loopback/eslint-config 17 (from 16), @loopback/testlab 9 and @types/node 22.
  • lb-tsc runs on @typescript/native 7.0.2. eslint and editors use typescript aliased to @typescript/typescript6.
  • typescript-eslint is pinned to ~8.72.2. From 8.73 it peers on the TypeScript 7.1 dev builds, which breaks npm ls.
  • engines and the CI matrix add Node.js 26 (22 || 24 || 26).
  • One lint-only source change with no behaviour change: the unused catch binding in src/providers/authorization-action.provider.ts is dropped (catch {}).
  • src/release_notes/ is added to .eslintignore. typescript-eslint 8 reports a parse error for JavaScript files outside the TypeScript project, and those scripts are only run by hand. It sits in .eslintignore rather than ignorePatterns so that it applies to lb-eslint, plain npx eslint . and editors alike.

Known limitation

LoopBack 7 declares engines: 20 || 22 || 24, so npm on Node.js 26 prints EBADENGINE warnings for the @loopback/* packages. These are warnings only. Install, build and tests work, and nothing fails unless engine-strict is set. Any LoopBack 7 app on Node.js 26 sees the same warnings from its own dependencies. They go away with LoopBack 8.

Type of change

  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

How has this been tested?

  • lb-tsc builds with TypeScript 7.0.2. Build and lint are clean.
  • npm test passes (21 tests) on Node.js 22, 24 and 26.
  • npm ls is clean. npm ci works on npm 10 and npm 11.
  • The package was installed into LoopBack 7 test apps (a bare app, a LoopBack 7 app, and a LoopBack 7 app with @sourceloop/core) on Node.js 22, 24 and 26. The install result matches the published 9.0.1 release, with one @loopback/core in the tree.
  • A monorepo with auth and audit services generated with the sl CLI was tested end to end on Node.js 26. Permission-based allow and deny checks pass (13 checks).
  • The published declaration files were checked from TypeScript 5.9.

Checklist

  • Performed a self-review of my own code
  • npm test passes on your machine
  • New tests added or existing tests modified to cover all changes
  • Code conforms with the style guide
  • API Documentation in code was updated
  • Any dependent changes have been merged and published in downstream modules

move dev tooling to @loopback/build 13, eslint-config 17, testlab 9,
@types/node 22 and typescript-eslint ~8.72.2. lb-tsc compiles with
typescript 7 (@typescript/native) and typescript is aliased to the
typescript 6 api for eslint.

add node 26 to engines and the ci matrix. runtime stays on loopback 7.

drop the unused catch binding in the authorization action provider and
add src/release_notes/ to .eslintignore, since typescript-eslint 8
fails to parse js files outside the ts project. no behaviour change.

GH-171

BREAKING CHANGE:
yes
@sonarqubecloud

sonarqubecloud Bot commented Dec 2, 2026

Copy link
Copy Markdown

@rohit-sourcefuse rohit-sourcefuse left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Thanks Piyush. I checked it out and ran it against master.

What I verified

  • npm ci --ignore-scripts, build, lint (npm run eslint and plain npx eslint .) and the 21 tests pass on master and on this branch, and npm ls exits 0 on both.
  • What consumers install does not change. The file list and .d.ts files are identical, and the compiled JS differs only in helper variable names and catch (error) becoming catch (_a). The only manifest change is engines gaining 26.
  • npm audit --omit=dev is 0 on both. All lockfile entries resolve from registry.npmjs.org, and no new package has an install script.
  • Putting src/release_notes/ in .eslintignore works for both lb-eslint and plain eslint.

Before merging: release version and notes

Same as audit-log#180. The repo squash-merges with the commit messages as the body, and I ran that message through the repo's semantic-release config: with the ! title and the BREAKING CHANGE: / yes footer it releases 10.0.0, and the BREAKING CHANGES section says yes.

Since nothing a consumer installs changes, I don't think this needs a major. @sourceloop/core and authentication-service depend on ^9.0.0, so 10.0.0 would need a catalog bump before anyone gets it. My suggestion is to squash as chore(deps): ... and delete the footer. If the team does want a major, please replace yes with a real note.

Approving, with the release note to sort out at squash time.

@rohit-sourcefuse
rohit-sourcefuse merged commit c9fb7e2 into master Dec 3, 2026
7 checks passed
@rohit-sourcefuse
rohit-sourcefuse deleted the GH-171 branch December 3, 2026 07:47
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.

Compile with TypeScript 7 and support Node.js 26

2 participants