Skip to content

ESLint

Terminal window
tinkerise add eslint

The eslint module treats the enhancement as installed when it finds any ESLint config file or an eslintConfig key in package.json.

Detection includes both flat and legacy file names:

  • eslint.config.js|mjs|cjs|ts
  • .eslintrc.js|cjs|json|yml|yaml

eslint always installs:

  • eslint
  • @eslint/js
  • globals

It conditionally installs:

  • typescript-eslint when TypeScript is already present
  • eslint-plugin-react for next, react, and remix
  • eslint-plugin-vue for vue and nuxt
  • eslint-plugin-svelte for svelte
  • eslint-plugin-astro for astro

The generated flat config is framework-aware and includes:

  • @eslint/js recommended rules
  • TypeScript rules when TypeScript is detected
  • Browser + Node globals from globals
  • Framework plugin config blocks when a supported framework is detected
  • Writes eslint.config.js for "type": "module" projects
  • Writes eslint.config.mjs for non-module projects
  • Adds a lint script: eslint .

Expected outcome after tinkerise add eslint:

  • ESLint config file at project root
  • New dev dependencies for your runtime/framework
  • package.json contains a working lint script

If ESLint config already exists, the executor treats it as a conflict. Interactive runs can show a diff and let you accept or skip changes.