Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Codefied-CodePix/KaroCar-platform/llms.txt

Use this file to discover all available pages before exploring further.

@repo/eslint-config provides a set of shared ESLint configuration presets for all KaroCar Platform workspaces. Three configs cover different environments: base (all TypeScript projects), next (Next.js applications), and react-internal (React library packages). By centralising lint rules in one place, every app and package in the monorepo stays consistently formatted and linted without duplicating configuration.
@repo/eslint-config is marked "private": true in its package.json and is not published to npm. It is consumed exclusively as an internal workspace dependency.

Installation

Reference the package from any workspace’s package.json using the workspace:* protocol:
"devDependencies": {
  "@repo/eslint-config": "workspace:*"
}
Then reference the relevant preset from that workspace’s eslint.config.mjs.

Configurations

base — All TypeScript Projects

The foundation shared by every other preset. Use this for any TypeScript package that doesn’t target Next.js or React specifically.Extends / integrates:
LayerPurpose
@eslint/js recommendedCore JavaScript best-practice rules
typescript-eslint recommendedTypeScript-aware lint rules
eslint-config-prettierDisables formatting rules that conflict with Prettier
eslint-plugin-turboTurbo-aware rules (env-var declarations)
eslint-plugin-only-warnDowngrades all rule violations to warnings
Source — base.js:
import js from "@eslint/js";
import eslintConfigPrettier from "eslint-config-prettier";
import turboPlugin from "eslint-plugin-turbo";
import tseslint from "typescript-eslint";
import onlyWarn from "eslint-plugin-only-warn";

export const config = [
  js.configs.recommended,
  eslintConfigPrettier,
  ...tseslint.configs.recommended,
  {
    plugins: { turbo: turboPlugin },
    rules: { "turbo/no-undeclared-env-vars": "warn" },
  },
  {
    plugins: { onlyWarn },
  },
  { ignores: ["dist/**"] },
];
Usage:
eslint.config.mjs
import { config } from "@repo/eslint-config/base";

export default config;

Key Rules

turbo/no-undeclared-env-vars

Warns whenever a Turbo pipeline task reads an environment variable that has not been declared in turbo.json. This prevents silent failures in CI where a variable is available locally but missing in the pipeline cache key.

eslint-plugin-only-warn

Converts every lint rule violation — across all extended configs — from an error to a warning. This keeps the developer experience non-blocking while still surfacing issues in the editor and in CI output.

Running the Linter

Run ESLint across all workspaces at once from the monorepo root:
# Via pnpm (executes the lint script in each workspace)
pnpm lint

# Via Turbo (respects caching and dependency graph)
turbo lint
Individual workspaces can also be linted in isolation:
pnpm --filter @karo-car/web lint

Build docs developers (and LLMs) love