I need a regex pattern to match camel case BEM classes following this structure:
BlockName_elementName-modifierName
I've created this regex to do the job:
([A-Z][a-z0-9]+)+(\_[a-z0-9]+[A-Z0-9]?[a-z0-9]*)?(\-[a-z0-9]+[A-Z0-9]?[a-z0-9]*)?
Examples of…
As part of my process I use stylelint to look for css errors before build and deploy for our site. However someone checked in the following which fails on the css parser / minifier but passed stylelint.
.example-class ,
/*.example-class-two span*/…
I am using the "selector-class-pattern" stylelint rule. The pattern I am using is to enforce the ECSS naming standard. The rule looks like this:
"selector-class-pattern":…
Hi sorry if this is a dumb question, I'm not so familiar with webpack and packages.
So I updated my Stylelint from 7.2.0 to 8.0.0 , but ever since I get this error when trying to run my project
edit: I reverted my project to before the update but…
Trying to use nesting rules via postcss, but getting warnings below. What rules I need to add in stylelint file to fix these warnings?
Here is the css:
.count-sec {
height: 520px;
& p {
color:#fff;
margin: 0;
…
To install styleline with npm.
sudo npm install -g stylelint
To install config file for stylelint.
sudo npm install stylelint-config-standard --save-dev -g
npm WARN stylelint-config-standard@16.0.0 requires a peer of stylelint@^7.8.0 but none was…
I'm trying to use autoprefixer in a project. And I'm setting indentation to 2 spaces and max line lenght to 80 characters. The thing is that these two settings seem to conflict with one another in several cases. Let's say i have:
@mixin…
I have installed WebStorm 2016.
Today I've installed stylelint, but I cant make it work.
I got error:
"C:\Program Files\nodejs\node.exe" "T:/project/html/node_modules/stylelint/bin/stylelint.js" -f json
Error: No configuration provided for…
I am working on Angular2 application with webpack. I am using sonarqube for code quality metrics. I use VS Code as IDE.
Below css gives me a warning on sonarqube "Check this potential box model size issue" which is correct.
.popup-dock-button {
…
I use gulp 3.9.1 and stylelint 7.6.0 for SCSS linting. OS is Ubuntu.
A related part of my gulp config looks like this:
var postcss = require('gulp-postcss');
var stylelint = require('stylelint');
var postcssReporter =…
I'm trying to hook up https://github.com/kungfusheep/SublimeLinter-contrib-stylelint to sublime... I've used SublimeLinter with the eslint and csslint addons before and they've worked perfectly.
After installing the stylelint everything seems to be…
I've configured stylelint to read SCSS and I keep getting browser hack warnings on SCSS items like $variables and !default. I loaded in the stylelint-scss plugin thinking this might fix it but it hasn't. I want the browser hacks rule to be enabled…
In stylelint or with any other tool is it possible if a developer is writing a class name in CSS file, for example, .somethingRed {} he gets a message that this class name has been already used if the similar class name has been used already in the…
I'm trying to create a separate task called stylelint because for reasons I do not want it to be part of the postcss task.
In the gruntfile I'm writing:
stylelint: {
options: {},
src: './assets/css/precss/**'
}
When I run grunt stylelint it…