Skip to content

refactor(schematics): update eslint config for TypeScript template - #2339

Closed
yousefdawood7 wants to merge 3 commits into
nestjs:masterfrom
yousefdawood7:refactor/update-eslint-config-ts
Closed

refactor(schematics): update eslint config for TypeScript template#2339
yousefdawood7 wants to merge 3 commits into
nestjs:masterfrom
yousefdawood7:refactor/update-eslint-config-ts

Conversation

@yousefdawood7

Copy link
Copy Markdown

PR Checklist

Please check if your PR fulfills the following requirements:

  • The commit message follows our guidelines
  • Tests for the changes have been added (not applicable)
  • Docs have been added / updated (not applicable)

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Other... Please describe:

What is the current behavior?

The generated ESLint configuration uses eslint.config.mjs but wraps configuration using tseslint.config(...), which is no longer necessary with the current flat config approach.

Additionally, the generated tsconfig.json includes baseUrl, which is discouraged in newer TypeScript setups and can lead to confusion when not required.

What is the new behavior?

  • Simplifies ESLint configuration by removing the tseslint.config(...) wrapper and using defineConfig directly
  • Keeps the existing eslint.config.mjs format aligned with modern flat config usage
  • Removes baseUrl from tsconfig.json to align with current TypeScript recommendations and reduce unnecessary configuration

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

  • Changes are minimal and scoped to generated templates only
  • Tested by generating a new NestJS project and verifying linting and compilation work as expected

@kamilmysliwiec

Copy link
Copy Markdown
Member

#2302

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