You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@krema/angular-eslint-stylelint-builder

Package Overview
Dependencies
Maintainers
0
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@krema/angular-eslint-stylelint-builder

Angular CLI builder for ESLint and stylelint

3.0.2
latest
Source
npmnpm
Version published
Maintainers
0
Created
Source

Angular ESLint + Stylelint Builder

npm version integration test unit test

A unified Angular CLI builder for linting Angular projects with ESLint and Stylelint in a single step.

Version Compatibility

The table below outlines the compatible versions for Angular, Stylelint, and ESLint with each major release of our tool:

VersionAngularStylelintESLint
v1.x9–15≤15≤8
v2.x16–1716+9+
v3.x18+16+9+

Features

  • Lint both TypeScript and stylesheets in one command
  • Supports ESLint and Stylelint configuration and ignore patterns
  • Output to file or console, with multiple formatter options
  • Caching for faster linting
  • Fine-grained control over warnings, errors, and exit codes

Prerequisites

  • Angular CLI project (v9+)
  • ESLint and Stylelint installed and configured (e.g., eslint.config.js for flat config, or .eslintrc for legacy config, and stylelint.config.js for Stylelint)

Installation

npm install --save-dev @krema/angular-eslint-stylelint-builder

Usage

  • Update your angular.json

    Replace the default lint builder with this one:

    "lint": {
      "builder": "@krema/angular-eslint-stylelint-builder:lint",
      "options": {
        "eslintFilePatterns": ["**/*.ts"],
        "stylelintFilePatterns": ["**/*.scss"]
      }
    }
    
  • Run linting

    ng lint
    

Configuration Options

NameDefaultDescriptionRequiredLinter
Basic configuration:
eslintFilePatterns[]Files/globs for ESLintYeseslint
eslintConfigPath to ESLint config (supports both flat config eslint.config.js and legacy .eslintrc.*)Noeslint
stylelintFilePatterns[]Files/globs for StylelintYesstylelint
stylelintConfigPath to Stylelint config (stylelint.config.js or legacy .stylelintrc.*)Nostylelint
noEslintrcfalseDisable .eslintrc.* and package.json configNoeslint
fixfalseAuto-fix fixable issuesNoboth
Cache-related:
eslintCachefalseEnable ESLint cacheNoeslint
stylelintCachefalseEnable Stylelint cacheNostylelint
eslintCacheLocation.eslintcacheESLint cache file/directoryNoeslint
stylelintCacheLocation.stylelintcacheStylelint cache file/directoryNostylelint
eslintCacheStrategymetadataESLint cache strategy (metadata or content)Noeslint
File Enumeration:
eslintIgnorePatterns[]Glob patterns to ignore (ESLint 9+)Noeslint
stylelintIgnorePatterns[]Glob patterns to ignore (Stylelint 16+)Nostylelint
Output:
outputFileWrite report to file instead of consoleNoboth
formatstylishOutput formatter (see ESLint formatters)Noboth
silentfalseHide output textNoboth
Handling warnings:
quietfalseOnly show errors (ignore warnings)Noboth
maxWarnings-1Max warnings before nonzero exit codeNoboth
forcefalseSucceed even if there are lint errorsNoboth

Example

"lint": {
  "builder": "@krema/angular-eslint-stylelint-builder:lint",
  "options": {
    "eslintFilePatterns": ["src/**/*.ts"],
    "stylelintFilePatterns": ["src/**/*.scss"],
    "fix": true
  }
}

License

MIT

Keywords

angular

FAQs

Package last updated on 26 Jul 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts