Skip to content

feat(cli): add strict type-checked ESLint via typescript-eslint#287

Open
gonzoblasco wants to merge 1 commit into
akd-io:developfrom
gonzoblasco:feature/263-eslint-proper-support
Open

feat(cli): add strict type-checked ESLint via typescript-eslint#287
gonzoblasco wants to merge 1 commit into
akd-io:developfrom
gonzoblasco:feature/263-eslint-proper-support

Conversation

@gonzoblasco

Copy link
Copy Markdown

What

Addresses #263

Adds --eslint-strict flag that enables strict type-checked linting using typescript-eslint (strict-type-checked + stylistic-type-checked configs).

Why

Issue #263 asks for proper ESLint support with @typescript-eslint, including the ability to choose between official configurations. The repo already evolved to include eslint-config-next/core-web-vitals + eslint-config-next/typescript and eslint-config-prettier, but was missing the option to use stricter type-checked configs.

This PR adds the most impactful part of the checklist: the ability to opt into strict type-checked linting with a single flag.

How

  • New plugin eslint-strict activated when --eslint-strict flag is set
  • Installs typescript-eslint as a devDependency
  • eslint.config.mjs is generated with tseslint.configs.strictTypeChecked and tseslint.configs.stylisticTypeChecked prepended before the Next.js configs
  • parserOptions with projectService: true and tsconfigRootDir are included for type-checked rules
  • Added typescript-eslint to the technologies sort order for README/landing page

What's left from #263

  • Choosing between next and next/core-web-vitals (currently always uses core-web-vitals)
  • Choosing between recommended, strict, stylistic and their type-checked variants individually

This PR provides the strict type-checked path. Further granularity can be added as follow-up.

Testing

  • tsc --noEmit passes
  • Unit tests pass (pnpm test:cli)

Addresses akd-io#263

Adds --eslint-strict flag that enables strict type-checked linting
using typescript-eslint (strict-type-checked + stylistic-type-checked
configs). When active:
- Installs typescript-eslint as a devDependency
- Generates eslint.config.mjs with strict/stylistic type-checked
  configs BEFORE next configs, plus parserOptions with projectService
- Adds typescript-eslint to the technologies list

The base ESLint setup (eslint-config-next with core-web-vitals and
typescript) remains unchanged when --eslint-strict is not passed.
@vercel

vercel Bot commented Jul 15, 2026

Copy link
Copy Markdown

@gonzoblasco is attempting to deploy a commit to the 9ty Team on Vercel.

A member of the Team first needs to authorize it.

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.

1 participant