Laint is an AI-focused linting SDK for JSX/TSX code, currently at v0.1.7 with weekly releases. It provides 50+ programmatic lint rules targeting React, React Native, Expo, and backend development, designed to be used by AI agents (e.g., Claude Code) via hooks. Unlike ESLint, Laint focuses on AI-generated code patterns like no-relative-paths, no-manual-retry-loop, and prefer-guard-clauses, and supports platform-specific rule sets (expo, web, backend). It offers include/exclude mode and a CLI, with zero setup for Claude Code integration.
npm install laintNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows programmatic linting with lintJsxCode and how to retrieve all rule names.
Pin to exact version and test upgrades.
Use prefer-guard-clauses or type guards instead.
Always provide an array for 'rules' when using exclude mode.
Use platform: 'expo' or others; setting both rules and platform may behave unexpectedly.
When integrating with Claude Code, check stderr for violations.
Run `npm install laint` and ensure node_modules contains it.
Use `import { lintJsxCode } from 'laint'` (ESM only).Change `import laint from 'laint'` to `import { lintJsxCode } from 'laint'`.Use `--hook` flag for Claude Code integration to get exit code 2 on violations.