NestJS v10 -> v11
To upgrade Nest from v10 to v11, please refer to the previous document for the basic part, related to updating Node and Nest, and installing/executing ncu. In this case, update everything.
The steps specific to this version update are as follows:
Add the following dependencies:
Remove the following ones:
In tsconfig.json, enable the following options:
strictNullChecks
forceConsistentCasingInFileNames
The ESLint file is now eslint.config.mjs, and has the following base template:
In the e2e test file, use
App
as type parameter forapp
and as type forserver
In the main file, prefix the
bootstrap()
call with void to explicitly not await it
With this, the project is updated. However, I'll make some more changes related to type safety strictness, as to make it more flexible:
In tsconfig.json, disable
strictNullChecks
In esling.config.mjs, in
rules
, disable the following options (mainly related to any handling):
This prevents errors in several parts of the system.
Commit - Upgrading from NestJS v10 to v11
Last updated