Socket
Book a DemoInstallSign in
Socket

@ebarooni/stylelint-config

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ebarooni/stylelint-config

A shareable Stylelint configuration for CSS, SCSS, and web projects

1.4.0
latest
Source
npmnpm
Version published
Weekly downloads
4
-20%
Maintainers
1
Weekly downloads
 
Created
Source

@ebarooni/stylelint-config

A shareable Stylelint configuration for enforcing best practices in CSS, SCSS, and other style sheets.

Prerequisites

Ensure the required peer dependencies are installed before using this package:

npm install -D stylelint stylelint-config-standard-scss

Installation

To install the package, run:

npm install -D @ebarooni/stylelint-config

Usage

Extend this configuration in your .stylelintrc.json file:

{
  "extends": ["@ebarooni/stylelint-config"]
}

Linting & Auto-Fixing Scripts

To simplify linting and fixing style files, add these scripts to your package.json:

{
  "scripts": {
    "stylelint": "npx stylelint",
    "stylelint:check": "npm run stylelint -- \"**/*.{css,scss}\"",
    "stylelint:fix": "npm run stylelint -- \"**/*.{css,scss}\" --fix"
  }
}

Run these commands:

  • Check for style errors:
    npm run stylelint:check
    
  • Automatically fix style issues:
    npm run stylelint:fix
    

Custom Configuration

This package supports custom rules, ignored files, and directory-specific overrides.

Ignoring Specific Files

To exclude certain files or directories, use the ignoreFiles field:

{
  "ignoreFiles": ["example/(ios|android)/**/*.{css,scss}"]
}

Directory-Specific Overrides

If you need different rules for specific directories, use the overrides field:

{
  "overrides": [
    {
      "files": ["example/**/*.{css,scss}"],
      "extends": ["@ebarooni/stylelint-config"]
    }
  ]
}

Keywords

stylelint

FAQs

Package last updated on 03 Feb 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

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.