You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 7-8.RSVP
Socket
Socket
Sign inDemoInstall

stylelint-config-recess-order

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stylelint-config-recess-order

Recess-based property sort order for Stylelint.


Version published
Weekly downloads
300K
increased by5.89%
Maintainers
1
Created
Weekly downloads
 

Package description

What is stylelint-config-recess-order?

The stylelint-config-recess-order package is a shareable configuration for Stylelint that enforces property order based on the Recess style guide. It helps maintain a consistent CSS property order in your stylesheets, which can improve readability and maintainability.

What are stylelint-config-recess-order's main functionalities?

Enforce Property Order

This feature enforces a specific order for CSS properties based on the Recess style guide. By extending the stylelint-config-recess-order configuration in your Stylelint configuration file, you ensure that your CSS properties are ordered consistently.

{
  "extends": "stylelint-config-recess-order"
}

Integration with Stylelint

This feature allows you to integrate the Recess order configuration with other Stylelint configurations. For example, you can combine it with the stylelint-config-standard to enforce both standard linting rules and property order.

{
  "extends": [
    "stylelint-config-standard",
    "stylelint-config-recess-order"
  ]
}

Other packages similar to stylelint-config-recess-order

Changelog

Source

5.0.1

Patch Changes

  • Add groups to package.json exports (#369)

Readme

Source

Recess* Property Order StyleLint

npm version npm downloads github issues

A Stylelint config that sorts CSS properties the way Recess did and Bootstrap did/does.

*With some modifications & additions for modern properties.

Usage

  1. Add stylelint and this package to your project:
    npm install --save-dev stylelint stylelint-config-recess-order
    
  2. Configure your stylelint configuration file to extend this package:
    module.exports = {
    	extends: ['stylelint-config-recess-order'],
    	rules: {
    		// Add overrides and additional rules here
    	},
    }
    

Advanced

The default setup applies only the 'order/properties-order' rule with the various property groups. If you need to configure other options for this rule, the groups can be imported separately and the rule configured to your needs.

const propertyGroups = require('stylelint-config-recess-order/groups')

module.exports = {
	extends: [], // Do not extend the config here.
	rules: {
		// Configure the rule manually.
		'order/properties-order': propertyGroups.map((group) => ({
			...group,
			emptyLineBefore: 'always',
			noEmptyLineBetween: true,
		})),
	},
}

References

@mdo on CSS Property Order

Keywords

FAQs

Package last updated on 15 Apr 2024

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

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc