Skip to content

Latest commit

 

History

History
66 lines (42 loc) · 3.05 KB

vision.md

File metadata and controls

66 lines (42 loc) · 3.05 KB

Vision

A linter for CSS and CSS-like languages that is:

  • Complete - with coverage of all standard CSS syntax.
  • Extensible - with multiple points of extension.
  • Configurable - with no defaults and plenty of options to tailor the linter.
  • Robust - with comprehensive test coverage and a wide range of fixtures.
  • Consistent - with conventions for behaviour, naming and documentation.
  • Performant - with tools to test and improve performance.

Complete

Provide built-in rules for the following three areas:

Possible errors

Provide rules to catch code that is valid but likely has unintended consequences e.g. duplicates and overrides.

Limit language features

Provide rules to limit what language features can be used, including:

  • Enforcing a maximum specificity by limiting the specificity itself or the occurrence of different selector types e.g. class, ID, attribute etc.
  • Enforcing best practices at the configuration level e.g. disallowing the all keyword for transitions as it is not performant.
  • Enforcing the use of a subset of features to improve consistency across a code base e.g. limiting what units are allowed (px or rem etc.)
  • Enforcing specific patterns for selectors and names (e.g. those of custom properties).

Stylistic issues

Provide rules to enforce a diverse range of stylistic conventions, including:

  • Whitespace
  • Case
  • Quotes

Extensible

Provide multiple points of extensions, including:

  • Plugins - build community rules to support methodologies, toolsets, non-standard CSS features, or very specific use cases.
  • Extendable configs - extend and share configurations.
  • Formatters - format stylelint result objects.
  • Custom syntax - use any PostCSS-compatible syntax module.

Robust

Provide a robust tool with a comprehensive test suite, including:

  • High coverage, currently over 95%.
  • A wide range of fixtures for rules, currently over 10000.

Consistent

Provide consistency throughout, including:

Performant

Provide a fast tool, and the means to test and improve performance, including benchmarking of an individual rule's performance.