Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

stylelint-config-werk85

Package Overview
Dependencies
Maintainers
3
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stylelint-config-werk85

Default stylelint configuration for all werk85 projects

  • 0.0.5-beta.1
  • beta
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
3
Weekly downloads
 
Created
Source

stylelint-config-werk85

Default stylelint configuration for all werk85 projects

Installation

yarn add stylelint-config-werk85 stylelint -D

Usage

Create a .stylelintrc.js file in your project root and add the following content

If using styled-components and scss

module.exports = {
  extends: [
    'stylelint-config-werk85/scss',
    'stylelint-config-werk85/styled'
  ]
}

If using scss without styled-components

module.exports = {
  extends: ['stylelint-config-werk85/scss']
}

If using css only

module.exports = {
  extends: ['stylelint-config-werk85']
}

For convenience you can add the following npm scripts to your package.json

{
  "scripts": {
    "lint:styles": "stylelint src/**/*.{css,scss,jsx,tsx}",
    "lint:styles:fix": "yarn lint:styles --fix",
  }
}

VScode extension

By default the stylelint extension >=1.0 validates only CSS and PostCSS files. Any other files (e.g. scss) must be added in the VScode config. Add javascriptreact and/or typescriptreact for styled-components.

"stylelint.validate": ["css", "postcss", "scss", "javascriptreact", "typescriptreact"]

Troubleshooting

Cannot resolve custom syntax module "@stylelint/postcss-css-in-js".

If stylint complaints that a custom syntax cannot be resolved then try to update postcss to >= 8.3.11 (e.g. via resolutions).

FAQs

Package last updated on 11 Nov 2021

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

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc